test: update encoding web-platform tests

PR-URL: https://github.com/nodejs/node/pull/53477
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
Yagiz Nizipli authored and GitHub committed 2024-06-18 19:39:49 +00:00
1 parent c93e256ee7
commit 99ac8829cf
24 files changed
+102 -10

No files matched your search

+1 -3
View File
@@ -6,9 +6,7 @@
test(() => {
const decoder = new TextDecoder('utf-8');
const buffer = new SharedArrayBuffer(4);
assert_throws_js(TypeError, () => {
decoder.decode(new Uint8Array(buffer));
}, 'constructing TextDecoder with SharedArrayBuffer view should throw');
assert_equals(decoder.decode(new Uint8Array(buffer)), "\u0000\u0000\u0000\u0000");
}, 'decoding SharedArrayBuffer');
</script>