Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove timeout in async_test for html tests #14087

Merged
merged 2 commits into from
Nov 22, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<pre id="step_log"></pre>
<iframe id="test"></iframe>
<script>
var t = async_test(undefined, {timeout:10000});
var t = async_test();
var f = document.getElementById("test");
var l = document.getElementById("step_log");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<pre id="step_log"></pre>
<iframe id="test"></iframe>
<script>
var t = async_test(undefined, {timeout:10000});
var t = async_test();
var f = document.getElementById("test");
var l = document.getElementById("step_log");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<form target="test" action="javascript:(function() {var x = new XMLHttpRequest(); x.open('GET', 'blank.html?pipe=trickle(d2)', false); x.send(); document.write('<script>parent.postMessage(&quot;write&quot;, &quot;*&quot;)</script>'); return '<script>parent.postMessage(&quot;click&quot;, &quot;*&quot;)</script>'})()"></form>
<a target="test" onclick="document.forms[0].submit()" href="href.html">Test</a>
<script>
var t = async_test(undefined, {timeout:4000});
var t = async_test();
t.step(function() {document.getElementsByTagName("a")[0].click()});
onmessage = t.step_func(
function(e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
javascript url involved here, unlike what the title claims! -->
<a target="test" onclick="javascript:(function() {var x = new XMLHttpRequest(); x.open('GET', 'blank.html?pipe=trickle(d2)', false); x.send(); document.write('write<script>parent.postMessage(&quot;write&quot;, &quot;*&quot;)</script>'); return '<script>parent.postMessage(&quot;click&quot;, &quot;*&quot;)</script>'})()" href="href.html">Test</a>
<script>
var t = async_test(undefined, {timeout:4000});
var t = async_test();
t.step(function() {document.getElementsByTagName("a")[0].click()});
onmessage = t.step_func(
function(e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<iframe id="test" name="test"></iframe>
<a target="test" href="javascript:parent.events.push('javascript');">Test</a>
<script>
var t = async_test(undefined, {timeout:4000});
var t = async_test();
var events = [];
t.step(function() {
document.getElementsByTagName("a")[0].click();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<form target="test" action="javascript:parent.events.push('submit');"></form>
<a target="test" onclick="document.forms[0].submit()">Test</a>
<script>
var t = async_test(undefined, {timeout:4000});
var t = async_test();
var events = [];
t.step(function() {
document.getElementsByTagName("a")[0].click();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<iframe id="test" name="test"></iframe>
<a target="test" onclick="parent.events.push('click');" href="javascript:parent.events.push('href')">Test</a>
<script>
var t = async_test(undefined, {timeout:4000});
var t = async_test();
var events = [];
t.step(function() {
document.getElementsByTagName("a")[0].click();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<iframe id="c" src='javascript:"%252525 ? %252525 # %252525"'></iframe>

<script>
var t = async_test("iframes with javascript src", {timeout:1000});
var t = async_test("iframes with javascript src");
function check(id, expected) {
assert_equals(
document.getElementById(id).contentDocument.body.textContent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
gone = false;
pages = []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
gone = false;
pages = []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
gone = false;
pages = []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:5000});
var t = async_test();
started = false;
pages = []
timer = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var win = window.open("manual_click_assign_during_load-1.html");

var history_length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var win = window.open("manual_click_location_replace_during_load-1.html");

var history_length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var win = window.open("manual_click_replace_during_load-1.html");

var history_length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var win = window.open("manual_form_submit_assign_during_load-1.html");

var history_length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000})
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var load_count = 0;
var resized = false;
var win = window.open("reload_in_resize-1.html")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var win = window.open("scripted_click_assign_during_load-1.html");

var history_length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<div id="log"></div>
<script>
setup({timeout:3600000});
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var win = window.open("scripted_form_submit_assign_during_load-1.html");

var history_length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined, {timeout:4000});
var t = async_test();
t.step(function() {
var w = window.open("close_script_defer-1.html");
w.document.open()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
<script src="/resources/testharnessreport.js"></script>
<div id="log"></div>
<script>
var t = async_test(undefined);
var t = async_test();
var w = window.open("discard_iframe_history_3-1.html");
</script>
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
<div id="log"></div>
<script>
setup({timeout:3600000})
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var w = window.open("discard_iframe_history_1-1.html");
</script>
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
<div id="log"></div>
<script>
setup({timeout:3600000})
var t = async_test(undefined, {timeout:3600000});
var t = async_test();
var w = window.open("discard_iframe_history_2-1.html");
</script>
2 changes: 1 addition & 1 deletion html/interaction/focus/focus-01.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
setup(function () {
testEle = document.getElementById("test");
testEle.focus();
}, {timeout: 10000});
});

document.onkeydown = t1.step_func_done(function(evt){
assert_equals(evt.target, testEle, "The keydown events must be targeted at the input element.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

setup(function () {
document.body.focus();
}, {timeout: 20000});
});



Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<div id="log"></div>
<script>
test(function() {
var t = async_test("setting src attribute on autoplay audio should trigger canplay event", {timeout:5000});
var t = async_test("setting src attribute on autoplay audio should trigger canplay event");
var a = document.getElementById("a");
a.addEventListener("error", t.unreached_func());
a.addEventListener("canplay", t.step_func(function() {
Expand All @@ -26,7 +26,7 @@
}, "audio events - canplay");

test(function() {
var t = async_test("setting src attribute on autoplay video should trigger canplay event", {timeout:5000});
var t = async_test("setting src attribute on autoplay video should trigger canplay event");
var v = document.getElementById("v");
v.addEventListener("error", t.unreached_func());
v.addEventListener("canplay", t.step_func(function() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
<div id="log"></div>
<script>
test(function () {
var t = async_test("setting src attribute on non-autoplay audio should trigger canplay event", {timeout:5000});
var t = async_test("setting src attribute on non-autoplay audio should trigger canplay event");
var a = document.getElementById("a");
a.addEventListener("error", t.unreached_func());
a.addEventListener("canplay", t.step_func_done(), false);
a.src = getAudioURI("/media/sound_5") + "?" + new Date() + Math.random();
}, "audio events - canplay");

test(function () {
var t = async_test("setting src attribute on non-autoplay video should trigger canplay event", {timeout:5000});
var t = async_test("setting src attribute on non-autoplay video should trigger canplay event");
var v = document.getElementById("v");
v.addEventListener("error", t.unreached_func());
v.addEventListener("canplay", t.step_func_done(), false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<div id="log"></div>
<script>
test(function() {
var t = async_test("setting src attribute on autoplay audio should trigger canplaythrough event", {timeout:5000});
var t = async_test("setting src attribute on autoplay audio should trigger canplaythrough event");
var a = document.getElementById("a");
a.addEventListener("error", t.unreached_func());
a.addEventListener("canplaythrough", t.step_func(function() {
Expand All @@ -26,7 +26,7 @@
}, "audio events - canplaythrough");

test(function() {
var t = async_test("setting src attribute on autoplay video should trigger canplaythrough event", {timeout:5000});
var t = async_test("setting src attribute on autoplay video should trigger canplaythrough event");
var v = document.getElementById("v");
v.addEventListener("error", t.unreached_func());
v.addEventListener("canplaythrough", t.step_func(function() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
<div id="log"></div>
<script>
test(function() {
var t = async_test("setting src attribute on non-autoplay audio should trigger canplaythrough event", {timeout:5000});
var t = async_test("setting src attribute on non-autoplay audio should trigger canplaythrough event");
var a = document.getElementById("a");
a.addEventListener("error", t.unreached_func());
a.addEventListener("canplaythrough", t.step_func_done(), false);
a.src = getAudioURI("/media/sound_5") + "?" + new Date() + Math.random();
}, "audio events - canplaythrough");

test(function() {
var t = async_test("setting src attribute on non-autoplay video should trigger canplaythrough event", {timeout:5000});
var t = async_test("setting src attribute on non-autoplay video should trigger canplaythrough event");
var v = document.getElementById("v");
v.addEventListener("error", t.unreached_func());
v.addEventListener("canplaythrough", t.step_func_done(), false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<div id="log"></div>
<script>
test(function() {
var t = async_test("setting src attribute on autoplay audio should trigger loadeddata event", {timeout:5000});
var t = async_test("setting src attribute on autoplay audio should trigger loadeddata event");
var a = document.getElementById("a");
a.addEventListener("error", t.unreached_func());
a.addEventListener("loadeddata", t.step_func(function() {
Expand All @@ -26,7 +26,7 @@
}, "audio events - loadeddata");

test(function() {
var t = async_test("setting src attribute on autoplay video should trigger loadeddata event", {timeout:5000});
var t = async_test("setting src attribute on autoplay video should trigger loadeddata event");
var v = document.getElementById("v");
v.addEventListener("error", t.unreached_func());
v.addEventListener("loadeddata", t.step_func(function() {
Expand Down
Loading