Commit cc5dc20c authored by morrita@google.com's avatar morrita@google.com
Browse files

2011-06-02 MORITA Hajime <morrita@google.com>

        Verify cloning <meter> and <progress> works
        https://bugs.webkit.org/show_bug.cgi?id=61986

        Added test cases for cloning <meter> and <progress>

        * fast/dom/HTMLMeterElement/meter-clone-expected.txt: Added.
        * fast/dom/HTMLMeterElement/meter-clone.html: Added.
        * fast/dom/HTMLProgressElement/progress-clone-expected.txt: Added.
        * fast/dom/HTMLProgressElement/progress-clone.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@88149 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 8f1212e3
2011-06-02 MORITA Hajime <morrita@google.com>
Verify cloning <meter> and <progress> works
https://bugs.webkit.org/show_bug.cgi?id=61986
Added test cases for cloning <meter> and <progress>
* fast/dom/HTMLMeterElement/meter-clone-expected.txt: Added.
* fast/dom/HTMLMeterElement/meter-clone.html: Added.
* fast/dom/HTMLProgressElement/progress-clone-expected.txt: Added.
* fast/dom/HTMLProgressElement/progress-clone.html: Added.
2011-06-06 Mustafizur Rahaman <mustaf.here@gmail.com>
Reviewed by Darin Adler.
......
PASS cloned.value is target.value
PASS layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild) is layoutTestController.shadowPseudoId(targetShadowRoot.firstChild)
PASS layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild.firstChild) is layoutTestController.shadowPseudoId(targetShadowRoot.firstChild.firstChild)
PASS clonedShadowRoot.firstChild.firstChild.style.width is "70%"
PASS targetShadowRoot.firstChild.firstChild.style.width is "50%"
PASS successfullyParsed is true
TEST COMPLETE
<html>
<head>
<link rel="stylesheet" href="../../js/resources/js-test-style.css">
<script src="../../js/resources/js-test-pre.js"></script>
</head>
<body>
<p id="description"></p>
<div id="console"></div>
<meter id="target" min="0" max="100" value="50" style="-webkit-appearance: none;" />
<script>
(function() {
target = document.getElementById("target");
cloned = target.cloneNode();
document.body.insertBefore(cloned, target.nextSibling);
if (!window.layoutTestController) {
debug("You need layoutTestController to run this test.");
return;
}
targetShadowRoot = layoutTestController.shadowRoot(target);
clonedShadowRoot = layoutTestController.shadowRoot(cloned);
shouldBe("cloned.value", "target.value");
shouldBe("layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild)", "layoutTestController.shadowPseudoId(targetShadowRoot.firstChild)");
shouldBe("layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild.firstChild)", "layoutTestController.shadowPseudoId(targetShadowRoot.firstChild.firstChild)");
cloned.value = 70;
shouldBe("clonedShadowRoot.firstChild.firstChild.style.width", '"70%"');
shouldBe("targetShadowRoot.firstChild.firstChild.style.width", '"50%"');
})();
var successfullyParsed = true;
</script>
<script src="../../js/resources/js-test-post.js"></script>
</body>
</html>
PASS cloned.value is target.value
PASS layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild) is layoutTestController.shadowPseudoId(targetShadowRoot.firstChild)
PASS layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild.firstChild) is layoutTestController.shadowPseudoId(targetShadowRoot.firstChild.firstChild)
PASS clonedShadowRoot.firstChild.firstChild.style.width is "70%"
PASS targetShadowRoot.firstChild.firstChild.style.width is "50%"
PASS successfullyParsed is true
TEST COMPLETE
<html>
<head>
<link rel="stylesheet" href="../../js/resources/js-test-style.css">
<script src="../../js/resources/js-test-pre.js"></script>
</head>
<body>
<p id="description"></p>
<div id="console"></div>
<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.layoutTestController) {
debug("You need layoutTestController to run this test.");
return;
}
targetShadowRoot = layoutTestController.shadowRoot(target);
clonedShadowRoot = layoutTestController.shadowRoot(cloned);
shouldBe("cloned.value", "target.value");
shouldBe("layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild)", "layoutTestController.shadowPseudoId(targetShadowRoot.firstChild)");
shouldBe("layoutTestController.shadowPseudoId(clonedShadowRoot.firstChild.firstChild)", "layoutTestController.shadowPseudoId(targetShadowRoot.firstChild.firstChild)");
cloned.value = 70;
shouldBe("clonedShadowRoot.firstChild.firstChild.style.width", '"70%"');
shouldBe("targetShadowRoot.firstChild.firstChild.style.width", '"50%"');
})();
var successfullyParsed = true;
</script>
<script src="../../js/resources/js-test-post.js"></script>
</body>
</html>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment