Skip to content

Commit

Permalink
HTML: document.open() and the unload event
Browse files Browse the repository at this point in the history
  • Loading branch information
annevk authored and TimothyGu committed Aug 1, 2018
1 parent 74938e8 commit fdc4468
Showing 1 changed file with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
async_test(t => {
const frame = document.body.appendChild(document.createElement("iframe"));
frame.src = "/common/blank.html";
frame.onload = t.step_func_done(() => {
let happened = 0;
frame.contentWindow.onpagehide = frame.contentWindow.onunload = t.step_func(() => {
happened++;
});
frame.contentDocument.open();
assert_equals(happened, 2);
frame.contentDocument.close();
});
}, "document.open() and the unload event");

0 comments on commit fdc4468

Please sign in to comment.