We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 04a9a7c commit e157b6dCopy full SHA for e157b6d
tests/testsuite/test.rs
@@ -3049,7 +3049,7 @@ fn cargo_test_env() {
3049
#[test]
3050
fn env_test() {{
3051
use std::env;
3052
- println!("{{}}", env::var("{}").unwrap());
+ eprintln!("{{}}", env::var("{}").unwrap());
3053
}}
3054
"#,
3055
cargo::CARGO_ENV
@@ -3062,13 +3062,17 @@ fn cargo_test_env() {
3062
3063
let cargo = cargo_exe().canonicalize().unwrap();
3064
p.cargo("test --lib -- --nocapture")
3065
- .with_stdout_contains(format!(
+ .with_stderr_contains(format!(
3066
"\
3067
{}
3068
-test env_test ... ok
3069
",
3070
cargo.to_str().unwrap()
3071
))
+ .with_stdout_contains(format!(
3072
+ "\
3073
+test env_test ... ok
3074
+",
3075
+ ))
3076
.run();
3077
}
3078
0 commit comments