| 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 <style> | 3 <style> | 
| 4 :empty + div { background-color: green } | 4 :empty + div { background-color: green } | 
| 5 </style> | 5 </style> | 
| 6 <div id="empty"></div> | 6 <div id="empty"></div> | 
| 7 <div id="emptySibling"> | 7 <div id="emptySibling"> | 
| 8     <div></div> | 8     <div></div> | 
| 9     <div></div> | 9     <div></div> | 
| 10     <div></div> | 10     <div></div> | 
| (...skipping 11 matching lines...) Expand all  Loading... | 
| 22 | 22 | 
| 23 var transparent = "rgba(0, 0, 0, 0)"; | 23 var transparent = "rgba(0, 0, 0, 0)"; | 
| 24 var green = "rgb(0, 128, 0)"; | 24 var green = "rgb(0, 128, 0)"; | 
| 25 | 25 | 
| 26 shouldBe("getComputedStyle(emptySibling, '').backgroundColor", "green"); | 26 shouldBe("getComputedStyle(emptySibling, '').backgroundColor", "green"); | 
| 27 | 27 | 
| 28 empty.offsetTop; // force recalc | 28 empty.offsetTop; // force recalc | 
| 29 empty.appendChild(document.createElement("div")); | 29 empty.appendChild(document.createElement("div")); | 
| 30 | 30 | 
| 31 if (window.internals) | 31 if (window.internals) | 
| 32     shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "7"); | 32     shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "2"); | 
| 33 | 33 | 
| 34 shouldBe("getComputedStyle(emptySibling, '').backgroundColor", "transparent"); | 34 shouldBe("getComputedStyle(emptySibling, '').backgroundColor", "transparent"); | 
| 35 | 35 | 
| 36 shouldBe("getComputedStyle(notEmptySibling, '').backgroundColor", "transparent")
    ; | 36 shouldBe("getComputedStyle(notEmptySibling, '').backgroundColor", "transparent")
    ; | 
| 37 | 37 | 
| 38 notEmpty.offsetTop; // force recalc | 38 notEmpty.offsetTop; // force recalc | 
| 39 notEmpty.removeChild(child); | 39 notEmpty.removeChild(child); | 
| 40 | 40 | 
| 41 if (window.internals) | 41 if (window.internals) | 
| 42     shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "6"); | 42     shouldBe("internals.updateStyleAndReturnAffectedElementCount()", "1"); | 
| 43 | 43 | 
| 44 shouldBe("getComputedStyle(notEmptySibling, '').backgroundColor", "green"); | 44 shouldBe("getComputedStyle(notEmptySibling, '').backgroundColor", "green"); | 
| 45 </script> | 45 </script> | 
| OLD | NEW | 
|---|