Local cargo test
broken if ~/.config/starship.toml
has add_newline = false
#5077
Labels
🐛 bug
Something isn't working as expected.
Current Behavior
cargo test
fails (6 tests) ifadd_newline = false
is in~/.config/starship.toml
, andSTARSHIP_CONFIG
is clear.The tests rely on the default config, i.e.
add_newline = true
Output:
Expected behaviour
The tests shouldn't depend on the
STARSHIP_CONFIG
environment variable, nor should they depend on the contents of~/.config/starship.toml
Possible Solution
Similar to how it is done in setup_config in configure.rs#setup_config in #5001
This is simple to fix after #5001 goes through, relevant changes in that PR around
Context::new
, see #5001 (comment):STARSHIP_CONFIG
is read from the env hashmapHOME
is in the env hashmap, it used instead ofutils::home_dir()
Environment
Relevant Shell Configuration
add_newline = false
The text was updated successfully, but these errors were encountered: