about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2018-05-06 22:29:01 +0000
committerbors <bors@rust-lang.org>2018-05-06 22:29:01 +0000
commit700165d7aeba7fbba79bcc322e010137ae70b46a (patch)
tree45cf222649688f1d200a21d1e42038848b238788
parent428ea5f6b9e7c6e5ee3294fe9f105e77e89ab407 (diff)
parentdf97dd1d05c1b1265b0ce5b929bc86f9780e821b (diff)
Auto merge of #50468 - nrc:test-rustfmt, r=alexcrichton
Pass a test directory to rustfmt

Another attempt to fix the rustfmt tests. `RUSTFMT_TEST_DIR` is consumed by Rustfmt in the latext commit (thus the Rustfmt update) because we need a place to create temp files that won't be read-only.

r? @alexcrichton
-rw-r--r--src/bootstrap/test.rs3
m---------src/tools/rustfmt10
2 files changed, 8 insertions, 5 deletions
diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs
index cbb952bab61..2865801742f 100644
--- a/src/bootstrap/test.rs
+++ b/src/bootstrap/test.rs
@@ -313,6 +313,9 @@ impl Step for Rustfmt {
 
         // Don't build tests dynamically, just a pain to work with
         cargo.env("RUSTC_NO_PREFER_DYNAMIC", "1");
+        let dir = testdir(builder, compiler.host);
+        t!(fs::create_dir_all(&dir));
+        cargo.env("RUSTFMT_TEST_DIR", dir);
 
         builder.add_rustc_lib_path(compiler, &mut cargo);
 
diff --git a/src/tools/rustfmt b/src/tools/rustfmt
-Subproject b6cd17f28ae314f2484ff05d3ce57652d51c5e8
+Subproject 0f8029f251b569a010cb5cfc5a8bff8bf3c949a