Bug 1440164 - Call SimpleTest.finish() in runSubtestsSeriallyInFreshWindows(), instead of relying on its caller to call it. r=kats
MozReview-Commit-ID: FeCVtMqkovQ
--- a/gfx/layers/apz/test/mochitest/apz_test_utils.js
+++ b/gfx/layers/apz/test/mochitest/apz_test_utils.js
@@ -242,17 +242,17 @@ function runSubtestsSeriallyInFreshWindo
w = spawnTest(test.file);
});
} else {
w = spawnTest(test.file);
}
}
advanceSubtestExecution();
- });
+ }).then(SimpleTest.finish);
}
function pushPrefs(prefs) {
return SpecialPowers.pushPrefEnv({'set': prefs});
}
function waitUntilApzStable() {
return new Promise(function(resolve, reject) {
--- a/gfx/layers/apz/test/mochitest/test_group_hittest.html
+++ b/gfx/layers/apz/test/mochitest/test_group_hittest.html
@@ -29,18 +29,17 @@ var prefs = [
var subtests = [
{'file': 'helper_hittest_basic.html', 'prefs': prefs},
{'file': 'helper_hittest_subframe_float.html', 'prefs': prefs},
];
if (isApzEnabled()) {
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>
--- a/gfx/layers/apz/test/mochitest/test_group_mouseevents.html
+++ b/gfx/layers/apz/test/mochitest/test_group_mouseevents.html
@@ -20,18 +20,17 @@ var subtests = [
{'file': 'helper_drag_scroll.html'},
// Test for dragging the scrollbar with a fixed-pos element overlaying it
{'file': 'helper_bug1346632.html'}
];
if (isApzEnabled()) {
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>
--- a/gfx/layers/apz/test/mochitest/test_group_overrides.html
+++ b/gfx/layers/apz/test/mochitest/test_group_overrides.html
@@ -20,18 +20,17 @@ var prefs = [
var subtests = [
{'file': 'helper_override_root.html', 'prefs': prefs},
{'file': 'helper_override_subdoc.html', 'prefs': prefs},
];
if (isApzEnabled()) {
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>
--- a/gfx/layers/apz/test/mochitest/test_group_pointerevents.html
+++ b/gfx/layers/apz/test/mochitest/test_group_pointerevents.html
@@ -14,18 +14,17 @@ https://bugzilla.mozilla.org/show_bug.cg
var subtests = [
{'file': 'helper_bug1285070.html', 'prefs': [["dom.w3c_pointer_events.enabled", true]]},
{'file': 'helper_bug1299195.html', 'prefs': [["dom.w3c_pointer_events.enabled", true]]}
];
if (isApzEnabled()) {
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>
--- a/gfx/layers/apz/test/mochitest/test_group_touchevents.html
+++ b/gfx/layers/apz/test/mochitest/test_group_touchevents.html
@@ -88,18 +88,17 @@ if (isApzEnabled()) {
ok(window.TouchEvent, "Check if TouchEvent is supported (it should be, the test harness forces it on everywhere)");
if (getPlatform() == "android") {
// This has a lot of subtests, and Android emulators are slow.
SimpleTest.requestLongerTimeout(2);
}
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>
--- a/gfx/layers/apz/test/mochitest/test_group_wheelevents.html
+++ b/gfx/layers/apz/test/mochitest/test_group_wheelevents.html
@@ -33,18 +33,17 @@ var subtests = [
{'file': 'helper_scroll_inactive_zindex.html', 'prefs': prefs},
{'file': 'helper_scroll_over_scrollbar.html', 'prefs': scrollbar_prefs},
{'file': 'helper_scroll_tables_perspective.html', 'prefs': prefs},
];
if (isApzEnabled()) {
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>
--- a/gfx/layers/apz/test/mochitest/test_group_zoom.html
+++ b/gfx/layers/apz/test/mochitest/test_group_zoom.html
@@ -28,18 +28,17 @@ var prefs = [
var subtests = [
{'file': 'helper_bug1280013.html', 'prefs': prefs},
{'file': 'helper_basic_zoom.html', 'prefs': prefs},
];
if (isApzEnabled()) {
SimpleTest.waitForExplicitFinish();
window.onload = function() {
- runSubtestsSeriallyInFreshWindows(subtests)
- .then(SimpleTest.finish);
+ runSubtestsSeriallyInFreshWindows(subtests);
};
}
</script>
</head>
<body>
</body>
</html>