3 <script src=
"../../../resources/js-test.js"></script>
6 div:-webkit-any(.outer) { width:
200px }
7 div:-webkit-any(.inner) { width:
300px }
8 div:-webkit-any(.inner2) { width:
150px }
20 description("Tests that a style recalc on the inner element after the outer one works correctly. See also crbug.com/346928.");
22 function insertStyleSheet(css
)
24 var styleElement
= document
.createElement("style");
25 styleElement
.textContent
= css
;
26 (document
.head
|| document
.documentElement
).appendChild(styleElement
);
29 var outer
= document
.getElementById('outer');
30 var inner
= document
.getElementById('inner');
34 outer
.className
= 'outer';
35 inner
.className
= 'inner';
37 shouldBe("getComputedStyle(outer).width", '"200px"');
39 inner
.className
= 'inner2';
40 shouldBe("getComputedStyle(inner).width", '"150px"');