]> git.lizzy.rs Git - rust.git/commitdiff
Use the workspace target directory
authorOliver Schneider <git-spam-no-reply9815368754983@oli-obk.de>
Wed, 17 May 2017 12:45:36 +0000 (14:45 +0200)
committerOliver Schneider <git-spam-no-reply9815368754983@oli-obk.de>
Wed, 17 May 2017 13:21:57 +0000 (15:21 +0200)
tests/compile-test.rs
tests/dogfood.rs

index 39a8380bc08633e6272d21ebe8c9b264515b4138..4c154859c7cd17e80f54ebeba9c40690dd155bd0 100644 (file)
@@ -7,14 +7,14 @@ fn run_mode(dir: &'static str, mode: &'static str) {
     let mut config = compiletest::default_config();
 
     let cfg_mode = mode.parse().expect("Invalid mode");
-    config.target_rustcflags = Some("-L target/debug/ -L target/debug/deps".to_owned());
+    config.target_rustcflags = Some("-L clippy_tests/target/debug/ -L clippy_tests/target/debug/deps".to_owned());
     if let Ok(name) = var::<&str>("TESTNAME") {
         let s: String = name.to_owned();
         config.filter = Some(s)
     }
 
     config.mode = cfg_mode;
-    config.build_base = PathBuf::from("target/debug/test_build_base");
+    config.build_base = PathBuf::from("clippy_tests/target/debug/test_build_base");
     config.src_base = PathBuf::from(format!("tests/{}", dir));
 
     compiletest::run_tests(&config);
index 83b2acf7d815bbade57d0d821101aa138e642469..e6b8d6f7d6cc608a19beaebf9d11ad04593dbac9 100644 (file)
@@ -22,8 +22,8 @@ fn dogfood() {
 
     let cfg_mode = "run-fail".parse().expect("Invalid mode");
     let mut s = String::new();
-    s.push_str(" -L target/debug/");
-    s.push_str(" -L target/debug/deps");
+    s.push_str(" -L clippy_tests/target/debug/");
+    s.push_str(" -L clippy_tests/target/debug/deps");
     s.push_str(" -Zextra-plugins=clippy -Ltarget_recur/debug -Dwarnings -Dclippy_pedantic -Dclippy -Dclippy_internal");
     config.target_rustcflags = Some(s);
     if let Ok(name) = var("TESTNAME") {