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

Unified Diff: LayoutTests/http/tests/fetch/script-tests/stream-reader.js

Issue 1028913002: ReadableStream.cancel's parameter should be optional. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 9 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
« no previous file with comments | « no previous file | Source/core/streams/ReadableStream.h » ('j') | Source/core/streams/ReadableStream.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/fetch/script-tests/stream-reader.js
diff --git a/LayoutTests/http/tests/fetch/script-tests/stream-reader.js b/LayoutTests/http/tests/fetch/script-tests/stream-reader.js
index 8e4d433c8ae1bbca427c041bd11d78915c73381d..7ec5ad803f385d225c3aa2a913a5b92aab9afed3 100644
--- a/LayoutTests/http/tests/fetch/script-tests/stream-reader.js
+++ b/LayoutTests/http/tests/fetch/script-tests/stream-reader.js
@@ -102,5 +102,16 @@ sequential_promise_test(function(t) {
});
}, 'Clone after reading partially');
+sequential_promise_test(function(t) {
+ var read = 0;
tyoshino (SeeGerritForStatus) 2015/03/23 03:57:21 remove
yhirano 2015/03/23 05:47:31 Reverted
+ var original;
+ return fetch('/fetch/resources/progressive.php').then(function(res) {
+ res.body.cancel();
+ return res.text();
+ }).then(function(text) {
+ assert_equals(text, '');
+ });
+ }, 'Cancelling stream stops downloading.');
+
sequential_promise_test_done();
done();
« no previous file with comments | « no previous file | Source/core/streams/ReadableStream.h » ('j') | Source/core/streams/ReadableStream.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698