3 <script src=
"/js-test-resources/js-test.js"></script>
5 window
.targetScaleFactor
= 2;
7 <script src=
"../resources/srcset-helper.js"></script>
8 <script src=
"http://127.0.0.1:8000/resources/slow-script.pl?delay=100"></script>
12 shouldBeFalse("internals.isPreloaded('resources/preload-test.jpg');");
13 shouldBeTrue("internals.isPreloaded('resources/base-image2.png');");
14 shouldBeFalse("internals.isPreloaded('resources/base-image1.png');");
15 shouldBeFalse("internals.isPreloaded('resources/base-image3.png');");
16 shouldBeTrue("internals.isPreloaded('resources/image2.png');");
18 <div>This test passes if the fallback image (defined in the src attribute) is not preloaded, but the
2x version (defined in srcset) is.
</div>
19 <div>The second image is here to make sure isPreloaded is working properly
</div>
20 <img height=
"100" width=
"100" src=
"resources/preload-test.jpg" srcset=
"resources/base-image1.png 1x, resources/base-image3.png 3x, resources/base-image2.png 2x">
21 <img src=
"resources/image2.png">