File tree Expand file tree Collapse file tree 1 file changed +3
-9
lines changed Expand file tree Collapse file tree 1 file changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ fn base_config(test_dir: &str) -> compiletest::Config {
3131 } ,
3232 dependencies_crate_manifest_path : Some ( "clippy_test_deps/Cargo.toml" . into ( ) ) ,
3333 target : None ,
34- out_dir : " target/ui_test ". into ( ) ,
34+ out_dir : PathBuf :: from ( std :: env :: var_os ( "CARGO_TARGET_DIR" ) . unwrap_or ( " target". into ( ) ) ) . join ( "ui_test" ) ,
3535 ..compiletest:: Config :: rustc ( Path :: new ( "tests" ) . join ( test_dir) )
3636 } ;
3737
@@ -116,10 +116,7 @@ fn run_ui_toml() {
116116
117117 config. stderr_filter (
118118 & regex:: escape (
119- & std:: path:: Path :: new ( file ! ( ) )
120- . parent ( )
121- . unwrap ( )
122- . canonicalize ( )
119+ & fs:: canonicalize ( "tests" )
123120 . unwrap ( )
124121 . parent ( )
125122 . unwrap ( )
@@ -175,10 +172,7 @@ fn run_ui_cargo() {
175172
176173 config. stderr_filter (
177174 & regex:: escape (
178- & std:: path:: Path :: new ( file ! ( ) )
179- . parent ( )
180- . unwrap ( )
181- . canonicalize ( )
175+ & fs:: canonicalize ( "tests" )
182176 . unwrap ( )
183177 . parent ( )
184178 . unwrap ( )
You can’t perform that action at this time.
0 commit comments