Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1242)

Unified Diff: third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html

Issue 2432863004: Fix ReadableStream getReader({mode: 'byob'}) (Closed)
Patch Set: Unconditionally throw if mode is 'byob' Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html b/third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html
new file mode 100644
index 0000000000000000000000000000000000000000..c1e3e3ecd5531a07be043c24cec97c7dd345e225
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/http/tests/streams/chromium/get-reader-byob.html
@@ -0,0 +1,11 @@
+<!DOCTYPE html>
+<meta charset="utf-8">
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<script>
+test(() => {
+ const rs = new ReadableStream();
+ assert_throws(new TypeError(), () => rs.getReader({mode: 'byob'}),
+ 'a TypeError should be thrown');
+}, 'getReader() with mode "byob" should throw a TypeError');
+</script>

Powered by Google App Engine
This is Rietveld 408576698