Skip to content

Commit f8e38d0

Browse files
committed
Fix the never_from_git_config_env_var test
So it fails too, as expected.
1 parent 340ff37 commit f8e38d0

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

gix-path/src/env/git/tests.rs

+4-5
Original file line numberDiff line numberDiff line change
@@ -581,11 +581,10 @@ mod exe_info {
581581
fn never_from_git_config_env_var() {
582582
let repo = gix_testtools::scripted_fixture_read_only("local_config.sh").expect("script succeeds");
583583

584-
// FIXME: exe_info() changes directory, so this is not seen, which results in this test
585-
// wrongly passing even if exe_info() does not really ensure GIT_CONFIG is ignore. So
586-
// either make this path an absolute non-UNC path (non-UNC to ensure all versions of Git
587-
// accept it) or use a newly created temporary file rather than the fixture.
588-
let config_path = repo
584+
// Get an absolute path to a config file that is non-UNC if possible so any Git accepts it.
585+
let config_path = std::env::current_dir()
586+
.expect("got CWD")
587+
.join(repo)
589588
.join(".git")
590589
.join("config")
591590
.to_str()

0 commit comments

Comments
 (0)