File tree 2 files changed +13
-1
lines changed
2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -267,7 +267,7 @@ pub fn test_opts(config: &Config) -> test::TestOpts {
267
267
logfile : config. logfile . clone ( ) ,
268
268
run_tests : true ,
269
269
run_benchmarks : true ,
270
- nocapture : false ,
270
+ nocapture : env :: var ( "RUST_TEST_NOCAPTURE" ) . is_ok ( ) ,
271
271
color : test:: AutoColor ,
272
272
}
273
273
}
Original file line number Diff line number Diff line change 8
8
// option. This file may not be copied, modified, or distributed
9
9
// except according to those terms.
10
10
11
+ use std:: env;
12
+
11
13
use common:: Config ;
12
14
use common;
13
15
use util;
@@ -125,6 +127,16 @@ pub fn load_props(testfile: &Path) -> TestProps {
125
127
true
126
128
} ) ;
127
129
130
+ for key in vec ! [ "RUST_TEST_NOCAPTURE" , "RUST_TEST_TASKS" ] {
131
+ match env:: var ( key) {
132
+ Ok ( val) =>
133
+ if exec_env. iter ( ) . find ( |& & ( ref x, _) | * x == key. to_string ( ) ) . is_none ( ) {
134
+ exec_env. push ( ( key. to_string ( ) , val) )
135
+ } ,
136
+ Err ( ..) => { }
137
+ }
138
+ }
139
+
128
140
TestProps {
129
141
error_patterns : error_patterns,
130
142
compile_flags : compile_flags,
You can’t perform that action at this time.
0 commit comments