Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / block / positioning / static-to-abspos-parent-is-stf.html
blob9fac651adba8a3605c3be29cef2e427ee2dfc9fe
1 <!DOCTYPE html>
2 <script src="../../../resources/check-layout.js"></script>
3 <p>Change from position:static to position:absolute when the parent is a shrink-to-fit container.
4 The parent needs to recalculate its intrinsic size when this happens.</p>
5 <p>There should be a black <em>square</em> below.</p>
6 <div id="container" style="float:left; border:20px solid black;" data-expected-width="40" data-expected-height="40">
7 <div id="test" style="width:100px; height:100px;"></div>
8 </div>
9 <p id="result" style="clear:both;"></p>
10 <script>
11 var test = document.getElementById("test");
12 test.offsetTop;
13 test.style.position = "absolute";
14 checkLayout("#container", document.getElementById("result"));
15 </script>