Skip to content

Commit

Permalink
Fix some tests on wasm
Browse files Browse the repository at this point in the history
  • Loading branch information
saethlin committed Apr 10, 2024
1 parent ad4f75c commit c7d595a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions tests/run-make/wasm-symbols-different-module/rmake.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ fn test_file(file: &str, expected_imports: &[(&str, &[&str])]) {
fn test(file: &str, args: &[&str], expected_imports: &[(&str, &[&str])]) {
println!("test {file:?} {args:?} for {expected_imports:?}");

rustc().input(file).target("wasm32-wasip1").args(args).run();
rustc().input(file).target("wasm32-wasip1").args(args).arg("-Zub-checks=no").run();

let file = std::fs::read(&tmp_dir().join(file).with_extension("wasm")).unwrap();

Expand All @@ -45,5 +45,5 @@ fn test(file: &str, args: &[&str], expected_imports: &[(&str, &[&str])]) {
assert!(names.contains(name));
}
}
assert!(imports.is_empty());
assert!(imports.is_empty(), "unexpected imports: {:?}", imports);
}
2 changes: 1 addition & 1 deletion tests/ui/numbers-arithmetic/saturating-float-casts-wasm.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//@ run-pass
//@ only-wasm32
//@ compile-flags: -Zmir-opt-level=0 -C target-feature=+nontrapping-fptoint
//@ compile-flags: -Zmir-opt-level=0 -Zub-checks=no -C target-feature=+nontrapping-fptoint

#![feature(test, stmt_expr_attributes)]
#![deny(overflowing_literals)]
Expand Down
2 changes: 1 addition & 1 deletion tests/ui/numbers-arithmetic/saturating-float-casts.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//@ run-pass
//@ compile-flags:-Zmir-opt-level=0
//@ compile-flags: -Zmir-opt-level=0 -Zub-checks=no

#![feature(test, stmt_expr_attributes)]
#![deny(overflowing_literals)]
Expand Down

0 comments on commit c7d595a

Please sign in to comment.