Specify target for inaccessible-temp-dir rmake test

This commit is contained in:
Ana Hobden 2024-06-19 11:57:03 -07:00
parent 5c8459f1ec
commit a656bb6eb2
No known key found for this signature in database

View File

@ -19,7 +19,7 @@
// Reason: `set_readonly` has no effect on directories // Reason: `set_readonly` has no effect on directories
// and does not prevent modification. // and does not prevent modification.
use run_make_support::{fs_wrapper, rustc, test_while_readonly}; use run_make_support::{fs_wrapper, rustc, target, test_while_readonly};
fn main() { fn main() {
// Create an inaccessible directory. // Create an inaccessible directory.
@ -28,6 +28,7 @@ fn main() {
// Run rustc with `-Z temps-dir` set to a directory *inside* the inaccessible one, // Run rustc with `-Z temps-dir` set to a directory *inside* the inaccessible one,
// so that it can't create `tmp`. // so that it can't create `tmp`.
rustc() rustc()
.target(&target())
.input("program.rs") .input("program.rs")
.arg("-Ztemps-dir=inaccessible/tmp") .arg("-Ztemps-dir=inaccessible/tmp")
.run_fail() .run_fail()