blob: 2331e8c8ba62fa97149def1ef4d699a61df2d0e5 [file] [log] [blame]
<html>
<head>
<script src="../../fast/dom/shadow/resources/polyfill.js"></script>
<script src="../../http/tests/inspector/inspector-test.js"></script>
<script src="../../http/tests/inspector/elements-test.js"></script>
<script>
function updateShadowDOM()
{
shadowRoot.removeChild(shadowRoot.firstChild);
}
function initialize_shadowSettings()
{
WebInspector.settings.showShadowDOM.set(true);
}
function test()
{
InspectorTest.expandElementsTree(function() {
InspectorTest.evaluateInPage("updateShadowDOM()", function() {
InspectorTest.expandElementsTree(function() {
var containerElem = InspectorTest.expandedNodeWithId('container');
InspectorTest.dumpElementsTree(containerElem);
InspectorTest.completeTest();
});
});
});
}
</script>
</head>
<body onload="runTest()">
<p id="description">This test confirms that updating the shadow dom is reflected to the Inspector.</p>
<div id="container">
<div id="host"></div>
</div>
<script>
var shadowRoot = host.webkitCreateShadowRoot();
shadowRoot.innerHTML = "<div></div>";
</script>
</body>
</html>