Skip to content
Permalink
Browse files

Use `t.step_func` and expected path checking

  • Loading branch information
notriddle committed Oct 29, 2018
1 parent 7270333 commit 10442ae894004ac18847793bc11bfa1c4653cb79
"support"
],
"html/semantics/forms/form-submission-target/form-target-iframe.html": [
"2309ca67bb58f20f06a4c0b6ed162f2d0c80217f",
"f37bc33f6f93ca94940ffeb0066945eb9aa020ee",
"testharness"
],
"html/semantics/forms/historical.html": [
@@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<script>
async_test(function(t) {
window.addEventListener("load", function() {
window.addEventListener("load", t.step_func(function() {
var frame = document.createElement("iframe");
frame.name = "frame";
document.documentElement.appendChild(frame);
@@ -17,13 +17,13 @@
form.appendChild(input);
document.documentElement.appendChild(form);
form.submit();
frame.addEventListener("load", function() {
if (frame.contentWindow.location.href != "about:blank") {
frame.addEventListener("load", t.step_func(function() {
if (frame.contentWindow.location.href.includes("form-target-iframe-helper.py")) {
assert_equals(frame.contentWindow.document.body.textContent, "OK");
t.done();
}
});
});
}));
}));
}, "Form targetted at iframe");
</script>
<body>

0 comments on commit 10442ae

Please sign in to comment.
You can’t perform that action at this time.