Skip to content

Commit

Permalink
Add history drop test
Browse files Browse the repository at this point in the history
  • Loading branch information
cbrewster authored and Servo WPT Sync committed Apr 12, 2018
1 parent a5bb6d2 commit c69c89f
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<body>Filler</body>
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<!doctype html>
<meta charset="utf-8">
<title>Joint session history length does not include entries from a removed iframe.</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<body>
<iframe id="frame" src="about:blank"></iframe>
<script>
async_test(function(t) {
t.step_timeout(() => {
var child = document.getElementById("frame");
var old_history_len = history.length;
child.onload = () => {
assert_equals(old_history_len + 1, history.length);
document.body.removeChild(document.getElementById("frame"));
assert_equals(old_history_len, history.length);
t.done();
}
child.src = "joint-session-history-filler.html";
}, 1000);
});
</script>
</body>

0 comments on commit c69c89f

Please sign in to comment.