mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-21 19:19:45 +00:00
improvements to llvm+wasm test running
- run only the wasm tests - nicer linker error reporting
This commit is contained in:
parent
f5c23a219a
commit
bece4342ec
1 changed files with 7 additions and 1 deletions
|
@ -452,9 +452,12 @@ fn llvm_module_to_wasm_file(
|
|||
.output()
|
||||
.unwrap();
|
||||
|
||||
if !output.stderr.is_empty() {
|
||||
panic!("{}", String::from_utf8_lossy(&output.stderr));
|
||||
}
|
||||
|
||||
assert!(output.status.success(), "{:#?}", output);
|
||||
assert!(output.stdout.is_empty(), "{:#?}", output);
|
||||
assert!(output.stderr.is_empty(), "{:#?}", output);
|
||||
|
||||
test_wasm_path
|
||||
}
|
||||
|
@ -586,6 +589,7 @@ macro_rules! assert_evals_to {
|
|||
$ignore_problems
|
||||
);
|
||||
|
||||
#[cfg(not(feature = "gen-llvm-wasm"))]
|
||||
$crate::helpers::llvm::assert_llvm_evals_to!(
|
||||
$src,
|
||||
$expected,
|
||||
|
@ -596,6 +600,7 @@ macro_rules! assert_evals_to {
|
|||
}};
|
||||
}
|
||||
|
||||
#[allow(unused_macros)]
|
||||
macro_rules! expect_runtime_error_panic {
|
||||
($src:expr) => {{
|
||||
#[cfg(feature = "gen-llvm-wasm")]
|
||||
|
@ -607,6 +612,7 @@ macro_rules! expect_runtime_error_panic {
|
|||
true // ignore problems
|
||||
);
|
||||
|
||||
#[cfg(not(feature = "gen-llvm-wasm"))]
|
||||
$crate::helpers::llvm::assert_llvm_evals_to!(
|
||||
$src,
|
||||
false, // fake value/type for eval
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue