@@ -354,6 +354,8 @@ fn custom_linker_env() {
354354}
355355
356356#[ cargo_test]
357+ // Temporarily disabled until https://github.com/rust-lang/rust/pull/85270 is in nightly.
358+ #[ cfg_attr( target_os = "windows" , ignore) ]
357359fn target_in_environment_contains_lower_case ( ) {
358360 let p = project ( ) . file ( "src/main.rs" , "fn main() {}" ) . build ( ) ;
359361
@@ -363,22 +365,16 @@ fn target_in_environment_contains_lower_case() {
363365 target. to_lowercase( ) . replace( '-' , "_" )
364366 ) ;
365367
366- let mut execs = p. cargo ( "build -v --target" ) ;
367- execs. arg ( target) . env ( & env_key, "nonexistent-linker" ) ;
368- if cfg ! ( windows) {
369- // Windows env keys are case insensitive, so no warning, but it will
370- // fail due to the missing linker.
371- execs
372- . with_stderr_does_not_contain ( "warning:[..]" )
373- . with_status ( 101 ) ;
374- } else {
375- execs. with_stderr_contains ( format ! (
376- "warning: Environment variables are expected to use uppercase letters and underscores, \
377- the variable `{}` will be ignored and have no effect",
368+ p. cargo ( "build -v --target" )
369+ . arg ( target)
370+ . env ( & env_key, "nonexistent-linker" )
371+ . with_stderr_contains ( format ! (
372+ "warning: Environment variables are expected to use uppercase \
373+ letters and underscores, the variable `{}` will be ignored and \
374+ have no effect",
378375 env_key
379- ) ) ;
380- }
381- execs. run ( ) ;
376+ ) )
377+ . run ( ) ;
382378}
383379
384380#[ cargo_test]
0 commit comments