Update web-platform-tests to revision ea14651f262003177d0ba5819bd2806a1327b12a

This commit is contained in:
WPT Sync Bot 2018-04-30 21:09:29 -04:00
parent 847115ba04
commit 816185f094
272 changed files with 5766 additions and 2855 deletions

View file

@ -0,0 +1,22 @@
// In an ideal world this test would eventually be obsolete due to mutation events disappearing. Or
// would have to change to account for mutation events not firing synchronously. Neither seems
// realistic to the author though.
test(t => {
const frame = document.body.appendChild(document.createElement("iframe"));
frame.contentWindow.addEventListener("DOMNodeInserted", t.unreached_func());
frame.contentWindow.addEventListener("DOMNodeInserted", t.unreached_func(), true);
frame.contentWindow.addEventListener("DOMNodeInsertedIntoDocument", t.unreached_func(), true);
frame.contentWindow.addEventListener("DOMNodeRemoved", t.unreached_func());
frame.contentWindow.addEventListener("DOMNodeRemoved", t.unreached_func(), true);
frame.contentWindow.addEventListener("DOMNodeRemovedFromDocument", t.unreached_func(), true);
frame.contentWindow.addEventListener("DOMSubtreeModified", t.unreached_func());
frame.contentWindow.addEventListener("DOMSubtreeModified", t.unreached_func(), true);
assert_equals(frame.contentDocument.documentElement.localName, "html");
frame.contentDocument.open();
assert_equals(frame.contentDocument.documentElement, null);
frame.contentDocument.write("<div>heya</div>");
frame.contentDocument.close();
assert_equals(frame.contentDocument.documentElement.localName, "html");
frame.remove();
}, "document.open(), the HTML parser, and mutation events");