OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <script src="../../resources/js-test.js"></script> | 2 <script src="../../resources/js-test.js"></script> |
3 <script> | 3 <script> |
4 if (window.testRunner) | 4 if (window.testRunner) |
5 testRunner.dumpAsText(); | 5 testRunner.dumpAsText(); |
6 if (window.internals) | |
7 internals.settings.setRegionBasedColumnsEnabled(true); | |
8 </script> | 6 </script> |
9 <body style="margin-left:10px; margin-top:15px;"> | 7 <body style="margin-left:10px; margin-top:15px;"> |
10 <div style="-webkit-columns:3; columns:3;" id="mc"> | 8 <div style="-webkit-columns:3; columns:3;" id="mc"> |
11 <div id="elm1" class="rodent">elm1</div> | 9 <div id="elm1" class="rodent">elm1</div> |
12 <br> | 10 <br> |
13 <div> | 11 <div> |
14 <div id="elm2" class="rodent">elm2</div> | 12 <div id="elm2" class="rodent">elm2</div> |
15 <div id="elm3" class="rodent">elm3</div> | 13 <div id="elm3" class="rodent">elm3</div> |
16 </div> | 14 </div> |
17 <div id="elm4" class="rodent">elm4</div> | 15 <div id="elm4" class="rodent">elm4</div> |
(...skipping 23 matching lines...) Expand all Loading... |
41 | 39 |
42 var elements = document.getElementsByClassName('rodent'); | 40 var elements = document.getElementsByClassName('rodent'); |
43 for (var i = 0; i < elements.length; i++) { | 41 for (var i = 0; i < elements.length; i++) { |
44 var rects = elements[i].getClientRects(); | 42 var rects = elements[i].getClientRects(); |
45 shouldBe("rects.length", "1"); | 43 shouldBe("rects.length", "1"); |
46 shouldBe("rects[0].left", "elements[i].offsetLeft"); | 44 shouldBe("rects[0].left", "elements[i].offsetLeft"); |
47 shouldBe("rects[0].top", "elements[i].offsetTop"); | 45 shouldBe("rects[0].top", "elements[i].offsetTop"); |
48 } | 46 } |
49 </script> | 47 </script> |
50 </body> | 48 </body> |
OLD | NEW |