blob: 4a551347b61f7bada1ceafe887ee4c5c2bba30a3 [file] [log] [blame]
<html>
<head>
<script src="../../../resources/js-test-pre.js"></script>
</head>
<body>
<progress id="target" min="0" max="100" value="50" style="-webkit-appearance: none;" ></progress>
<script>
(function() {
target = document.getElementById("target");
cloned = target.cloneNode();
document.body.insertBefore(cloned, target.nextSibling);
if (!window.internals) {
debug("You need internals to run this test.");
return;
}
targetShadowRoot = internals.shadowRoot(target);
clonedShadowRoot = internals.shadowRoot(cloned);
shouldBe("cloned.value", "target.value");
shouldBe("internals.shadowPseudoId(clonedShadowRoot.firstChild.firstChild)", "internals.shadowPseudoId(targetShadowRoot.firstChild.firstChild)");
shouldBe("internals.shadowPseudoId(clonedShadowRoot.firstChild.firstChild.firstChild)", "internals.shadowPseudoId(targetShadowRoot.firstChild.firstChild.firstChild)");
cloned.value = 70;
shouldBe("clonedShadowRoot.firstChild.firstChild.firstChild.style.width", '"70%"');
shouldBe("targetShadowRoot.firstChild.firstChild.firstChild.style.width", '"50%"');
})();
</script>
<script src="../../../resources/js-test-post.js"></script>
</body>
</html>