Skip to content

Commit

Permalink
test: enable idlharness tests for encoding
Browse files Browse the repository at this point in the history
TextDecoderStream and TextEncoderStream are now exposed as globals,
so we can run the entire Encoding idlharness test suite.

PR-URL: #50778
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
  • Loading branch information
MattiasBuelens authored and RafaelGSS committed Nov 29, 2023
1 parent 12605e8 commit 0e3b714
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion test/common/wpt.js
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ class WPTRunner {
'ReadableStreamBYOBReader', 'ReadableStreamBYOBRequest',
'ReadableByteStreamController', 'ReadableStreamDefaultController',
'ByteLengthQueuingStrategy', 'CountQueuingStrategy',
'TextEncoderStream', 'TextDecoderStream',
'TextEncoder', 'TextDecoder', 'TextEncoderStream', 'TextDecoderStream',
'CompressionStream', 'DecompressionStream',
];
if (Boolean(process.versions.openssl) && !process.env.NODE_SKIP_CRYPTO) {
Expand Down
2 changes: 1 addition & 1 deletion test/wpt/status/encoding.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"skip": "The iso-8859-16 encoding is not supported"
},
"idlharness.any.js": {
"skip": "No implementation of TextDecoderStream and TextEncoderStream"
"requires": ["small-icu"]
},
"idlharness-shadowrealm.window.js": {
"skip": "ShadowRealm support is not enabled"
Expand Down
2 changes: 2 additions & 0 deletions test/wpt/test-encoding.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,6 @@
const { WPTRunner } = require('../common/wpt');
const runner = new WPTRunner('encoding');

runner.pretendGlobalThisAs('Window');

runner.runJsTests();

0 comments on commit 0e3b714

Please sign in to comment.