Skip to content

Commit afc4eca

Browse files
authored
test: fix wasm error expectation (#8494)
1 parent 99e016b commit afc4eca

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/core/test/wasm.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ test('imports from "data:application/wasm" URI without explicit encoding fail',
4848
expect(error).toMatchInlineSnapshot(`[Error: Missing data URI encoding]`)
4949
}
5050
else {
51-
expect(error).toMatchInlineSnapshot(`[CompileError: data:application/wasm,AGFzbQEAAAABBwFgAn9/AX8DAgEABwcBA2FkZAAACgkBBwAgACABags=: WebAssembly.compile(): expected magic word 00 61 73 6d, found 41 47 46 7a @+0]`)
51+
expect(error).toMatchObject({ name: 'CompileError' })
5252
}
5353
})
5454

@@ -59,7 +59,7 @@ test('imports from "data:application/wasm" URI with invalid encoding fail', asyn
5959
expect(error).toMatchInlineSnapshot(`[Error: Invalid data URI encoding: charset=utf-8]`)
6060
}
6161
else {
62-
expect(error).toMatchInlineSnapshot(`[CompileError: data:application/wasm;charset=utf-8,oops: WebAssembly.compile(): expected magic word 00 61 73 6d, found 6f 6f 70 73 @+0]`)
62+
expect(error).toMatchObject({ name: 'CompileError' })
6363
}
6464
})
6565

0 commit comments

Comments
 (0)