diff --git a/test/browser/test_async_compile.c b/test/browser/test_async_compile.c
index 8fe940e333092..a58b180d00256 100644
--- a/test/browser/test_async_compile.c
+++ b/test/browser/test_async_compile.c
@@ -14,6 +14,7 @@ int main() {
int result = EM_ASM_INT({
return Module.sawAsyncCompilation | 0;
});
+ printf("sawAsyncCompilation => %d\n", result);
return result;
}
diff --git a/test/test_browser.py b/test/test_browser.py
index 2bd8adb6a711f..531bfecb926ae 100644
--- a/test/test_browser.py
+++ b/test/test_browser.py
@@ -4469,7 +4469,16 @@ def test_in_flight_memfile_request(self, args, expected):
# should happen when there is a mem init file (-O2+)
self.btest('in_flight_memfile_request.c', expected=expected)
- def test_async_compile(self):
+ @parameterized({
+ '': ([], 1),
+ 'O1': (['-O1'], 1),
+ 'O2': (['-O2'], 1),
+ 'O3': (['-O3'], 1),
+ # force it on
+ 'force': (['-sWASM_ASYNC_COMPILATION'], 1),
+ 'off': (['-sWASM_ASYNC_COMPILATION=0'], 0),
+ })
+ def test_async_compile(self, opts, returncode):
# notice when we use async compilation
script = '''
'
+ no_streaming = ''
shell_with_script('shell.html', 'shell.html', no_streaming + script)
self.btest_exit('test_async_compile.c', assert_returncode=1, args=common_args)