mirror of
https://github.com/servo/servo.git
synced 2025-06-29 11:33:39 +01:00
15 lines
559 B
JavaScript
15 lines
559 B
JavaScript
// META: global=worker
|
|
|
|
'use strict';
|
|
|
|
test(t => {
|
|
assert_throws(new TypeError(), () => new DecompressionStream('a'), 'constructor should throw');
|
|
}, '"a" should cause the constructor to throw');
|
|
|
|
test(t => {
|
|
assert_throws(new TypeError(), () => new DecompressionStream(), 'constructor should throw');
|
|
}, 'no input should cause the constructor to throw');
|
|
|
|
test(t => {
|
|
assert_throws(new Error(), () => new DecompressionStream({ toString() { throw Error(); } }), 'constructor should throw');
|
|
}, 'non-string input should cause the constructor to throw');
|