| <!doctype html> |
| <html> |
| <body onload="runTest()";> |
| <div id='sandbox'></div> |
| <script> |
| if (window.testRunner) |
| testRunner.waitUntilDone(); |
| |
| var sandbox = document.getElementById('sandbox'); |
| var host = document.createElement('p'); |
| var shadowRoot = host.attachShadow({mode: 'open'}); |
| shadowRoot.innerHTML = '<style>div { width: 100px; height: 100px; }</style><div></div>'; |
| sandbox.appendChild(host); |
| document.body.offsetLeft; |
| shadowRoot.styleSheets[0].insertRule('@import url(../resources/css-insert-import-rule.css);', 0); |
| |
| function runTest() { |
| setTimeout(function(){ |
| if (window.testRunner) |
| testRunner.notifyDone(); |
| }, 0); |
| } |
| </script> |
| </body> |
| </html> |