File tree Expand file tree Collapse file tree 4 files changed +29
-22
lines changed Expand file tree Collapse file tree 4 files changed +29
-22
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,6 @@ run-make/dump-mono-stats/Makefile
2626run-make/emit-path-unhashed/Makefile
2727run-make/emit-shared-files/Makefile
2828run-make/emit-to-stdout/Makefile
29- run-make/env-dep-info/Makefile
3029run-make/export-executable-symbols/Makefile
3130run-make/extern-diff-internal-name/Makefile
3231run-make/extern-flag-disambiguates/Makefile
@@ -65,7 +64,6 @@ run-make/issue-36710/Makefile
6564run-make/issue-37839/Makefile
6665run-make/issue-47551/Makefile
6766run-make/issue-69368/Makefile
68- run-make/issue-83045/Makefile
6967run-make/issue-83112-incr-test-moved-file/Makefile
7068run-make/issue-84395-lto-embed-bitcode/Makefile
7169run-make/issue-85019-moved-src-dir/Makefile
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ // Inside dep-info emit files, #71858 made it so all accessed environment
2+ // variables are usefully printed. This test checks that this feature works
3+ // as intended by checking if the environment variables used in compilation
4+ // appear in the output dep-info files.
5+ // See https://github.com/rust-lang/rust/issues/40364
6+
7+ use run_make_support:: { fs_wrapper, rustc} ;
8+
9+ // FIXME(Oneirical): try on musl
10+
11+ fn main ( ) {
12+ rustc ( )
13+ . env ( "EXISTING_ENV" , "1" )
14+ . env ( "EXISTING_OPT_ENV" , "1" )
15+ . emit ( "dep-info" )
16+ . input ( "main.rs" )
17+ . run ( ) ;
18+ let dep_info = fs_wrapper:: read_to_string ( "main.d" ) ;
19+ assert ! ( & dep_info. contains( "# env-dep:EXISTING_ENV=1" ) ) ;
20+ assert ! ( & dep_info. contains( "# env-dep:EXISTING_OPT_ENV=1" ) ) ;
21+ assert ! ( & dep_info. contains( "# env-dep:NONEXISTENT_OPT_ENV" ) ) ;
22+ assert ! ( dep_info. contains( r#"# env-dep:ESCAPE\nESCAPE\\"# ) ) ;
23+ // Procedural macro
24+ rustc ( ) . input ( "macro_def.rs" ) . run ( ) ;
25+ rustc ( ) . env ( "EXISTING_PROC_MACRO_ENV" , "1" ) . emit ( "dep-info" ) . input ( "macro_use.rs" ) . run ( ) ;
26+ let dep_info = fs_wrapper:: read_to_string ( "macro_use.d" ) ;
27+ assert ! ( & dep_info. contains( "# env-dep:EXISTING_PROC_MACRO_ENV=1" ) ) ;
28+ assert ! ( dep_info. contains( "# env-dep:NONEXISTENT_PROC_MACEO_ENV" ) ) ;
29+ }
Original file line number Diff line number Diff line change @@ -27,7 +27,6 @@ fn main() {
2727 . input ( "b.rs" )
2828 . arg ( "--verbose" )
2929 . run ( ) ;
30- fs_wrapper:: create_dir ( "wrong_directory" ) ;
3130 bare_rustc ( )
3231 . extern_ ( "b" , rust_lib_name ( "b" ) )
3332 . crate_type ( "rlib" )
You can’t perform that action at this time.
0 commit comments