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

Side by Side Diff: LayoutTests/fast/dom/HTMLImageElement/image-srcset-in-iframe.html

Issue 674163002: Test that only the right resource is loaded in iframes. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | LayoutTests/fast/dom/HTMLImageElement/image-srcset-in-iframe-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script src="../../../resources/js-test.js"></script>
Mike West 2014/10/24 15:18:26 Can you (perhaps in a future CL?) start migrating
3 <script>
4 var img;
5 var jsTestIsAsync = true;
6
7 if (window.internals)
8 internals.evictAllResources();
9
10 window.addEventListener("message", function() {
11 if (window.internals) {
12 shouldBeFalse('window.internals.isLoadingFromMemoryCache("resources/ image-set-4x.png")');
13 shouldBeTrue('window.internals.isLoadingFromMemoryCache("resources/b lue_rect.jpg")');
14 }
15 finishJSTest();
16 });
17 </script>
18
19 <iframe id="frame" style="width: 80px;"></iframe>
20 <script>
21 var iframe = document.getElementById('frame');
22 var iframeDoc = iframe.contentWindow.document;
23
24 iframeDoc.body.innerHTML = '<img id="srcset" srcset="resources/blue_rect.jpg 90w , resources/image-set-4x.png 120w">';
25 var img = iframeDoc.getElementById('srcset');
26 img.onload = function() {
27 window.parent.postMessage("loaded", "*");
28 };
29 </script>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/dom/HTMLImageElement/image-srcset-in-iframe-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698