Ensure rustc-echo-wrapper works with an overridden build.target-dir

This commit is contained in:
Wim Looman 2022-07-29 15:56:30 +02:00
parent 1fcbca84ee
commit 61c4b11eae
No known key found for this signature in database
GPG Key ID: C6F5748C6DD1607B

View File

@ -1209,7 +1209,7 @@ pub trait TestEnv: Sized {
.current_dir(&paths::root())
.env("HOME", paths::home())
.env("CARGO_HOME", paths::home().join(".cargo"))
.env("__CARGO_TEST_ROOT", paths::root())
.env("__CARGO_TEST_ROOT", paths::global_root())
// Force Cargo to think it's on the stable channel for all tests, this
// should hopefully not surprise us as we add cargo features over time and
// cargo rides the trains.