OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <script src="../../../resources/js-test.js"></script> |
| 3 <script src="resources/shadow-dom.js"></script> |
| 4 <style> |
| 5 .test { width: 100px; height: 100px; } |
| 6 </style> |
| 7 <div class="test"></div> |
| 8 <div class="test"></div> |
| 9 <script> |
| 10 function insertIntoShadowRoot(element) { |
| 11 var shadowRoot = element.createShadowRoot(); |
| 12 shadowRoot.innerHTML = '<div style="all: initial; display: block; width:100%;
height: 100%; background: black"></div>'; |
| 13 } |
| 14 var tests = document.querySelectorAll('.test'); |
| 15 insertIntoShadowRoot(tests[0]); |
| 16 insertIntoShadowRoot(tests[1]); |
| 17 |
| 18 description('Test for issue 432257: Matched properties cache should work for all
property.'); |
| 19 var targets = document.querySelectorAll('.test::shadow > div'); |
| 20 shouldBe('window.getComputedStyle(targets[0]).width', '"100px"'); |
| 21 shouldBe('window.getComputedStyle(targets[1]).width', '"100px"'); |
| 22 </script> |
OLD | NEW |