summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/web/06_streams.js5
-rw-r--r--tools/wpt/expectation.json32
2 files changed, 6 insertions, 31 deletions
diff --git a/ext/web/06_streams.js b/ext/web/06_streams.js
index 15f51ca7a..ed77dde66 100644
--- a/ext/web/06_streams.js
+++ b/ext/web/06_streams.js
@@ -55,7 +55,6 @@
WeakMapPrototypeSet,
} = globalThis.__bootstrap.primordials;
const consoleInternal = window.__bootstrap.console;
- const { DOMException } = window.__bootstrap.domException;
class AssertionError extends Error {
constructor(msg) {
@@ -1872,7 +1871,7 @@
let abortAlgorithm;
if (signal) {
abortAlgorithm = () => {
- const error = new DOMException("Aborted", "AbortError");
+ const error = signal.reason;
/** @type {Array<() => Promise<void>>} */
const actions = [];
if (preventAbort === false) {
@@ -3343,7 +3342,7 @@
if (state === "closed" || state === "errored") {
return resolvePromiseWith(undefined);
}
- stream[_controller][_signal][signalAbort]();
+ stream[_controller][_signal][signalAbort](reason);
if (state === "closed" || state === "errored") {
return resolvePromiseWith(undefined);
}
diff --git a/tools/wpt/expectation.json b/tools/wpt/expectation.json
index b20326939..4ec7cea21 100644
--- a/tools/wpt/expectation.json
+++ b/tools/wpt/expectation.json
@@ -5787,28 +5787,8 @@
"idlharness.any.html": true,
"idlharness.any.worker.html": true,
"piping": {
- "abort.any.html": [
- "(reason: 'null') all the error objects should be the same object",
- "(reason: 'undefined') all the error objects should be the same object",
- "(reason: 'error1: error1') all the error objects should be the same object",
- "(reason: 'null') abort should prevent further reads",
- "(reason: 'undefined') abort should prevent further reads",
- "(reason: 'error1: error1') abort should prevent further reads",
- "(reason: 'null') all pending writes should complete on abort",
- "(reason: 'undefined') all pending writes should complete on abort",
- "(reason: 'error1: error1') all pending writes should complete on abort"
- ],
- "abort.any.worker.html": [
- "(reason: 'null') all the error objects should be the same object",
- "(reason: 'undefined') all the error objects should be the same object",
- "(reason: 'error1: error1') all the error objects should be the same object",
- "(reason: 'null') abort should prevent further reads",
- "(reason: 'undefined') abort should prevent further reads",
- "(reason: 'error1: error1') abort should prevent further reads",
- "(reason: 'null') all pending writes should complete on abort",
- "(reason: 'undefined') all pending writes should complete on abort",
- "(reason: 'error1: error1') all pending writes should complete on abort"
- ],
+ "abort.any.html": true,
+ "abort.any.worker.html": true,
"close-propagation-backward.any.html": true,
"close-propagation-backward.any.worker.html": true,
"close-propagation-forward.any.html": true,
@@ -5907,12 +5887,8 @@
"terminate.any.worker.html": true
},
"writable-streams": {
- "aborting.any.html": [
- "WritableStreamDefaultController.signal"
- ],
- "aborting.any.worker.html": [
- "WritableStreamDefaultController.signal"
- ],
+ "aborting.any.html": true,
+ "aborting.any.worker.html": true,
"bad-strategies.any.html": true,
"bad-strategies.any.worker.html": true,
"bad-underlying-sinks.any.html": true,