Update web-platform-tests to revision c2e5b9fbaa17424f05ca2bb04609790a3b61d5c2

This commit is contained in:
WPT Sync Bot 2019-03-17 21:51:47 -04:00 committed by Josh Matthews
parent db7bb2a510
commit f2c1b70e4a
138 changed files with 2799 additions and 851 deletions

View file

@ -0,0 +1,19 @@
// Make sure that the load event for an iframe doesn't fire at the
// point when a navigation triggered by document.write() starts in it,
// but rather when that navigation completes.
async_test(t => {
const frame = document.body.appendChild(document.createElement("iframe"));
const doc = frame.contentDocument;
const url = URL.createObjectURL(new Blob(["PASS"], { type: "text/html"}));
frame.onload = t.step_func_done(() => {
assert_equals(frame.contentDocument.body.textContent, "PASS",
"Why is our load event firing before the new document loaded?");
});
doc.open();
doc.write(`FAIL<script>location = "${url}"</` + "script>");
doc.close();
}, "Setting location from document.write() call should not trigger load event until that load completes");