diff --git a/streams/writable-streams/constructor.any.js b/streams/writable-streams/constructor.any.js index 0abc7ef545ea0b..bb382a33b8e0c4 100644 --- a/streams/writable-streams/constructor.any.js +++ b/streams/writable-streams/constructor.any.js @@ -87,6 +87,10 @@ test(() => { new WritableStream(); }, 'WritableStream should be constructible with no arguments'); +test(() => { + assert_throws_js(RangeError, () => new WritableStream({ type: 'bytes' }), 'constructor should throw'); +}, `WritableStream can't be constructed with a defined type`); + test(() => { const underlyingSink = { get start() { throw error1; } }; const queuingStrategy = { highWaterMark: 0, get size() { throw error2; } };