blob: 21e69e1ab5dc4cc244f12907610cf814778e1443 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<title>Test the parent adopts node</title>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
</head>
<body>
<div id="target"></div>
<script>
setup({single_test: true});
var target = document.getElementById("target");
var attr = target.attributes[0];
var anotherDocument = document.implementation.createDocument("http://www.w3.org/1999/xhtml", "", null);
anotherDocument.title = "Hello";
anotherDocument.adoptNode(target);
assert_equals(attr.ownerDocument.title, anotherDocument.title);
done();
</script>
</body>
</html>