Automatic update from web-platform-testsStreams: Modify tests to expect abort reason passthrough (#9926) This tests the changes in https://github.com/whatwg/streams/pull/903. Replace expectations that a TypeError will be stored after abort() is called with with expectations that the reason passed to abort() will be stored instead. Also add a test of the stored error on the readable side of a TransformStream after abort() has been called on the writable size. This was not explicitly tested. Also fix a bug in the general.js test: it didn't wrap a call to assert_unreached properly, so a failure would have shown up as an unhandled rejection rather than being reported properly. wpt-commits: 81468a0b88d771af9dfa0feb5de99367e32d4b6e wpt-pr: 9926 wpt-commits: 81468a0b88d771af9dfa0feb5de99367e32d4b6e wpt-pr: 9926
Streams Tests
The work on the streams tests is closely tracked by the specification authors, who maintain a reference implementation intended to match the spec line-by-line while passing all of these tests. See the whatwg/streams repository for details. Some tests may be in that repository while the spec sections they test are still undergoing heavy churn.
Generating wrapper files
Because the streams feature is supposed to work in all global contexts, each test is written as a .js file, and then four .html files are generated around it. So for example, for count-queueing-strategy.js, we have the wrapper files:
count-queueing-strategy.https.htmlcount-queueing-strategy.dedicatedworker.htmlcount-queueing-strategy-sharedworker.htmlcount-queueing-strategy-serviceworker.html
These are generated automatically by the Node.js script in generate-test-wrappers.js. See it for details, and please remember to use it whenever adding new tests.