Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / loading / preload-image-srcset-duplicate.html
blob1d51404f64bf7e0efab66a4d8f6ec5c52ea82e42
1 <html>
2 <head>
3 <script src="/js-test-resources/js-test.js"></script>
4 <script>
5 window.targetScaleFactor = 1;
6 </script>
7 <script src="../resources/srcset-helper.js"></script>
8 <script src="http://127.0.0.1:8000/resources/slow-script.pl?delay=100"></script>
9 </head>
10 <body>
11 <script>
12 shouldBeFalse("internals.isPreloaded('resources/preload-test.jpg');");
13 shouldBeFalse("internals.isPreloaded('resources/preload-test-duplicate.jpg');");
14 shouldBeTrue("internals.isPreloaded('resources/base-image1.png');");
15 shouldBeFalse("internals.isPreloaded('resources/base-image2.png');");
16 shouldBeFalse("internals.isPreloaded('resources/base-image3.png');");
17 shouldBeFalse("internals.isPreloaded('resources/dup-image1.png');");
18 shouldBeFalse("internals.isPreloaded('resources/dup-image2.png');");
19 shouldBeFalse("internals.isPreloaded('resources/dup-image3.png');");
20 shouldBeTrue("internals.isPreloaded('resources/image2.png');");
21 </script>
22 <div>This test passes if the fallback image (defined in the src attribute) is not preloaded, the 1x version (defined in srcset) is, and none
23 of the duplicate resources is preloaded.</div>
24 <div>The second image is here to make sure isPreloaded is working properly</div>
25 <img height="100" width="100" src="resources/preload-test.jpg" src="resources/preload-test-duplicate.jpg"
26 srcset="resources/base-image1.png 1x, resources/base-image3.png 3x, resources/base-image2.png 2x"
27 srcset="resources/dup-image1.png 1x, resources/dup-image3.png 3x, resources/dup-image2.png 2x">
28 <img src="resources/image2.png">
29 </body>
30 </html>