diff --git a/tests/testsuite/mock-std/library/compiler_builtins/src/lib.rs b/tests/testsuite/mock-std/library/compiler_builtins/src/lib.rs index 65e2cc34045..0c9ac1ac8e4 100644 --- a/tests/testsuite/mock-std/library/compiler_builtins/src/lib.rs +++ b/tests/testsuite/mock-std/library/compiler_builtins/src/lib.rs @@ -1 +1 @@ -// intentionally blank +#![no_std] diff --git a/tests/testsuite/mock-std/library/core/src/lib.rs b/tests/testsuite/mock-std/library/core/src/lib.rs index b90ed091414..fd317cb1d69 100644 --- a/tests/testsuite/mock-std/library/core/src/lib.rs +++ b/tests/testsuite/mock-std/library/core/src/lib.rs @@ -1,3 +1,4 @@ +#![no_std] #![feature(staged_api)] #![stable(since = "1.0.0", feature = "dummy")] diff --git a/tests/testsuite/standard_lib.rs b/tests/testsuite/standard_lib.rs index afcc79f750b..214df036561 100644 --- a/tests/testsuite/standard_lib.rs +++ b/tests/testsuite/standard_lib.rs @@ -395,12 +395,13 @@ fn test_std_on_unsupported_target() { let p = project() .file( - "src/main.rs", + "src/lib.rs", r#" - fn main() { - println!("hello"); - } - "#, + #![no_std] + pub fn foo() { + assert_eq!(u8::MIN, 0); + } + "#, ) .build();