mirror of
https://github.com/zebrajr/node.git
synced 2026-01-15 12:15:26 +00:00
PR-URL: https://github.com/nodejs/node/pull/43958 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Feng Yu <F3n67u@outlook.com> Reviewed-By: Darshan Sen <raisinten@gmail.com>
15 lines
434 B
HTML
15 lines
434 B
HTML
<!DOCTYPE html>
|
|
<script src="/resources/testharness.js"></script>
|
|
<script src="/resources/testharnessreport.js"></script>
|
|
<script>
|
|
|
|
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');
|
|
}, 'decoding SharedArrayBuffer');
|
|
|
|
</script>
|