blob: 711908b91e0cfffd3ed135422ce3f1538ebc6957 [file] [log] [blame]
<!DOCTYPE html>
<html>
<body onload="runTest()">
<p>This tests moving a node list that uses string gets adopted to a new document properly.<br>
The test passes if WebKit does not hit an assertion.</p>
<script>
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.waitUntilDone();
}
function runTest()
{
var newDocument = document.implementation.createDocument(null, "someElement", null);
var fragment = document.createDocumentFragment();
newDocument.documentElement.getElementsByClassName("foo");
fragment.appendChild(newDocument.documentElement);
setTimeout(function () {
document.querySelector('p').innerHTML += '<br><br>PASS';
if (window.testRunner)
testRunner.notifyDone();
}, 0);
}
</script>
</body>
</html>