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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1.html

Issue 1800333003: Keep multipart images in m_nonBlockingLoaders after first part loaded (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reflect comments. Created 4 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 | third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading.html b/third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1.html
similarity index 62%
copy from third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading.html
copy to third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1.html
index 31383c786d877efd8849bad27efb24badd8db683..dfcf6bc3defe45f84ab85292d7773ed5c046d26a 100644
--- a/third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading.html
+++ b/third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1.html
@@ -1,12 +1,14 @@
<html>
<head>
<script>
+// This tests window.stop() can stop loading of multipart images after
+// <img>'s onload and before the next part loaded after onload.
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.waitUntilDone();
}
-function firstPartLoaded()
+function callStop()
{
window.stop();
window.setTimeout(function() {
@@ -16,10 +18,16 @@ function firstPartLoaded()
testRunner.notifyDone();
}, 100);
}
+
+function firstPartLoaded()
+{
+ setTimeout(callStop, 0);
+}
</script>
</head>
<body>
-<img id=testingImage src="resources/multipart.php?interval=1&loop=1&img1=2x2-green.png&img2=abe.png" onload="firstPartLoaded()">
+<!-- |label| is added to avoid interaction between stop-loading* tests -->
+<img id=testingImage src="resources/multipart.php?interval=1&loop=1&img1=2x2-green.png&img2=abe.png&label=1" onload="firstPartLoaded()">
<p id="results"></p>
</body>
</html>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/multipart/stop-loading-after-onload1-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698