summaryrefslogtreecommitdiffstats
path: root/js/src/tests/non262/ReadableStream/tee-start.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/tests/non262/ReadableStream/tee-start.js')
-rw-r--r--js/src/tests/non262/ReadableStream/tee-start.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/js/src/tests/non262/ReadableStream/tee-start.js b/js/src/tests/non262/ReadableStream/tee-start.js
new file mode 100644
index 0000000000..dbb6b1142d
--- /dev/null
+++ b/js/src/tests/non262/ReadableStream/tee-start.js
@@ -0,0 +1,11 @@
+// |reftest| skip-if(!this.ReadableStream||!this.drainJobQueue)
+// stream.tee() shouldn't try to call a .start() method.
+
+Object.prototype.start = function () { throw "FAIL"; };
+let source = Object.create(null);
+new ReadableStream(source).tee();
+
+drainJobQueue();
+
+if (typeof reportCompare == 'function')
+ reportCompare(0, 0);