Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / css3 / flexbox / relayout-image-load.html
blob93c6c2cc48cf1dae90f9094958ed129f1cc4eaac
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <link href="resources/flexbox.css" rel="stylesheet">
5 <style>
6 </style>
7 <script src="../../resources/check-layout.js"></script>
8 </head>
9 <body>
10 <p>Test to make sure that we properly relayout when an image loads. You
11 should see a green 100x100 image.</p>
12 <div id="test" class="flexbox">
13 &nbsp;
14 <div class="flexbox">
15 <img data-expected-width=100 data-expected-height=100 id="image" onload="imageLoaded()">
16 </div>
17 </div>
18 <script>
19 if (window.testRunner)
20 testRunner.waitUntilDone();
22 function changeImage()
24 document.getElementById("image").src = "../images/resources/green-100.png";
26 setTimeout(changeImage, 0);
28 function imageLoaded()
30 checkLayout('#test')
31 if (window.testRunner)
32 testRunner.notifyDone();
34 </script>
35 </body>
36 </html>