about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-06-04 19:14:28 +0000
committerbors <bors@rust-lang.org>2024-06-04 19:14:28 +0000
commit23e040adec50e10d3ff8103e405ff79e44908e70 (patch)
tree28b96be2482499ce61f77b3ccc33ce998c488e2f
parent44701e070c8453df10df1984944258018ac21610 (diff)
parent2949195d9a9728b388cc606cb03d7ee3e00f5e7b (diff)
downloadrust-23e040adec50e10d3ff8103e405ff79e44908e70.tar.gz
rust-23e040adec50e10d3ff8103e405ff79e44908e70.zip
Auto merge of #125426 - jieyouxu:rmake-support-env-reset, r=saethlin
Update `compiler-builtins` test to not clear essential env vars

Noticed in https://github.com/rust-lang/rust/pull/122580#issuecomment-2125755689, the `compiler-builtins` test failed on Windows for a `cargo` invocation because necessary env vars `TMP` and `TEMP` were cleared by `Command::env_clear`, causing temp dir eventually used by codegen to fallback to the Windows directory, which will trigger permission errors.

This PR removes the `env_clear` on the cargo invocation.

r? `@saethlin` (feel free to reroll, since you authored the test)

try-job: x86_64-msvc
try-job: test-various
-rw-r--r--tests/run-make/compiler-builtins/rmake.rs1
1 files changed, 0 insertions, 1 deletions
diff --git a/tests/run-make/compiler-builtins/rmake.rs b/tests/run-make/compiler-builtins/rmake.rs
index f5da50ebb04..55962fa4ebc 100644
--- a/tests/run-make/compiler-builtins/rmake.rs
+++ b/tests/run-make/compiler-builtins/rmake.rs
@@ -56,7 +56,6 @@ fn main() {
         "--target",
         &target,
     ])
-    .env_clear()
     .env("PATH", path)
     .env("RUSTC", rustc)
     .env("RUSTFLAGS", "-Copt-level=0 -Cdebug-assertions=yes")