blob: 9325c4e27645b704c090ec6ca6656dadd04f1f9e [file] [log] [blame]
<!DOCTYPE html>
<html>
<body>
<script src="../../resources/js-test-pre.js"></script>
<script>
description("Tests that we are using the right global object for DOM callbacks.");
jsTestIsAsync = true;
var f = document.body.appendChild(document.createElement("iframe"));
f.onload = function() {
f.onload = null;
try {
var iterator = document.createNodeIterator(document, NodeFilter.SHOW_ALL, f.contentWindow);
iterator.nextNode();
} catch(e) {
window.nextNodeError = e;
}
shouldBe("nextNodeError.constructor", "f.contentWindow.TypeError");
finishJSTest();
};
f.src = "resources/empty-body.html";
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>