summaryrefslogtreecommitdiff
path: root/cli/tests/unit/wasm_test.ts
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests/unit/wasm_test.ts')
-rw-r--r--cli/tests/unit/wasm_test.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/cli/tests/unit/wasm_test.ts b/cli/tests/unit/wasm_test.ts
index 3484b7f81..1b31249d4 100644
--- a/cli/tests/unit/wasm_test.ts
+++ b/cli/tests/unit/wasm_test.ts
@@ -45,11 +45,11 @@ Deno.test(
Deno.test(
async function wasmInstantiateStreamingNoContentType() {
+ const response = new Response(simpleWasm);
+ // Rejects, not throws.
+ const wasmPromise = WebAssembly.instantiateStreaming(response);
await assertRejects(
- async () => {
- const response = Promise.resolve(new Response(simpleWasm));
- await WebAssembly.instantiateStreaming(response);
- },
+ () => wasmPromise,
TypeError,
"Invalid WebAssembly content type.",
);