Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / hidpi / image-srcset-remove-dynamically-from-js.html
blobda48f31cf3531396213a803fec59940f779e02bd
1 <html>
2 <head>
3 <script>
4 window.targetScaleFactor = 1;
5 </script>
6 <script src="resources/srcset-helper.js"></script>
7 <script src="../../resources/js-test.js"></script>
8 <script>
9 if (window.testRunner) {
10 testRunner.dumpAsText();
13 function updateSrc() {
14 var img = document.getElementById("foo");
15 // srcset must be set first, otherwise 'src' is loaded as well
16 img.src = "";
19 addEventListener("DOMContentLoaded", function() {
20 updateSrc();
21 }, false);
22 addEventListener("load", function() {
23 shouldBeTrue('document.getElementById("foo").clientWidth==200');
24 }, false);
25 </script>
26 </head>
27 <body id="body">
28 <div>This test passes if this img tag below is a green square. It ensures that attributes can be removed dynamically from javascript</div>
29 <img id="foo" src="resources/blue-100-px-square.png" srcset="resources/green-400-px-square.png 2x">
30 </body>
31 </html>