From 50c7b893692fb6563952ab18ef8ad0f682944976 Mon Sep 17 00:00:00 2001 From: Marcos Casagrande Date: Fri, 14 Oct 2022 11:29:01 +0200 Subject: fix(ext/web/streams): resolve cancelPromise in ReadableStreamTee (#16266) --- ext/web/06_streams.js | 4 +++- tools/wpt/expectation.json | 8 ++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ext/web/06_streams.js b/ext/web/06_streams.js index 09e5b7414..933d7b09c 100644 --- a/ext/web/06_streams.js +++ b/ext/web/06_streams.js @@ -2675,7 +2675,9 @@ ], ); } - cancelPromise.resolve(undefined); + if (canceled1 === false || canceled2 === false) { + cancelPromise.resolve(undefined); + } }, errorSteps() { reading = false; diff --git a/tools/wpt/expectation.json b/tools/wpt/expectation.json index d5560ffb6..e9dfa03d0 100644 --- a/tools/wpt/expectation.json +++ b/tools/wpt/expectation.json @@ -1336,8 +1336,12 @@ "patched-global.any.worker.html": true, "reentrant-strategies.any.html": true, "reentrant-strategies.any.worker.html": true, - "tee.any.html": false, - "tee.any.worker.html": false, + "tee.any.html": [ + "ReadableStream teeing: enqueue() and close() while both branches are pulling" + ], + "tee.any.worker.html": [ + "ReadableStream teeing: enqueue() and close() while both branches are pulling" + ], "templated.any.html": true, "templated.any.worker.html": true }, -- cgit v1.2.3