servo/tests/wpt/meta/encoding
minghuaw 554b2da1ad
Script: Implement TextDecoderStream (#38112)
This PR implements the `TextDecoderStream`. Other than introducing the
necessary mod and webidl files corresponding to `TextDecoderStream`,
this PR also involves some changes in `TextDecoder` and
`TrasnformStream`:

- The common part that can be shared between `TextDecoder` and
`TextDecoderStream` are extracted into a separate type
`script::dom::textdecodercommon::TextDecoderCommon`. This type could
probably use a different name because there is an interface called
`TextDecoderCommon` in the spec
(https://encoding.spec.whatwg.org/#textdecodercommon) which just gets
included in `TextDecoder` and `TextDecoderStream`.
- The three algorithms in `TransformStream` (`cancel`, `flush`, and
`transform`) all have become `enum` that has a `Js` variant for a JS
function object and a `Native` variant for a rust trait object. Whether
the cancel algorithm needs this enum type is debatable as I did not find
any interface in the spec that explicitly sets the cancel algorithm.

Testing: Existing WPT tests `tests/wpt/tests/encoding/stream` should be
sufficient
Fixes: #37723

---------

Signed-off-by: minghuaw <michael.wu1107@gmail.com>
Signed-off-by: minghuaw <wuminghua7@huawei.com>
Signed-off-by: Minghua Wu <michael.wu1107@gmail.com>
2025-07-29 04:18:15 +00:00
..
legacy-mb-schinese Script: Implement TextDecoderStream (#38112) 2025-07-29 04:18:15 +00:00
streams Script: Implement TextDecoderStream (#38112) 2025-07-29 04:18:15 +00:00
api-basics.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
api-surrogates-utf8.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
big5-encoder.html.ini Run same tests for layout-2020 and layout-2013 (#30092) 2023-08-15 00:28:32 +00:00
encodeInto.any.js.ini script: Implement TextEncoder::encodeInto() (#33360) 2024-09-09 14:40:12 +00:00
idlharness.any.js.ini Script: Implement TextDecoderStream (#38112) 2025-07-29 04:18:15 +00:00
iso-2022-jp-decoder.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
iso-2022-jp-encoder.html.ini Rename metadata directories 2023-06-22 21:15:41 +02:00
remove-only-one-bom.html.ini Run same tests for layout-2020 and layout-2013 (#30092) 2023-08-15 00:28:32 +00:00
sharedarraybuffer.https.html.ini Rename metadata directories 2023-06-22 21:15:41 +02:00
single-byte-decoder.window.js.ini Use spec compliant content-type extraction in more places and enable a <stylesheet> quirk (#28321) 2025-05-19 11:38:01 +00:00
sniffing.html.ini Run same tests for layout-2020 and layout-2013 (#30092) 2023-08-15 00:28:32 +00:00
textdecoder-arguments.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
textdecoder-byte-order-marks.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
textdecoder-copy.any.js.ini Rename metadata directories 2023-06-22 21:15:41 +02:00
textdecoder-fatal-streaming.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
textdecoder-fatal.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
textdecoder-ignorebom.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
textdecoder-streaming.any.js.ini Rename metadata directories 2023-06-22 21:15:41 +02:00
textdecoder-utf16-surrogates.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
textencoder-utf16-surrogates.any.js.ini Update web-platform-tests to revision b'bf49dde84c5f05613115d6146d109f0ec3900694' (#34483) 2024-12-05 05:23:07 +00:00
unsupported-labels.window.js.ini Run same tests for layout-2020 and layout-2013 (#30092) 2023-08-15 00:28:32 +00:00
utf-32-from-win1252.html.ini Run same tests for layout-2020 and layout-2013 (#30092) 2023-08-15 00:28:32 +00:00