blob: fe7de74e7c3c640ce608b1ea2c96a94fe5245dc4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
// |jit-test| skip-if: !this.hasOwnProperty("ReadableStream")
// Don't assert if the wrapper that's the value of reader.[[stream]] gets nuked.
load(libdir + "asserts.js");
let g = newGlobal({newCompartment: true});
let stream = new g.ReadableStream({});
let reader = ReadableStream.prototype.getReader.call(stream);
nukeCCW(stream);
assertErrorMessage(() => reader.read(), TypeError, "can't access dead object");
assertErrorMessage(() => reader.releaseLock(), TypeError, "can't access dead object");
|