Diff
Modified: trunk/LayoutTests/ChangeLog (211572 => 211573)
--- trunk/LayoutTests/ChangeLog 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/ChangeLog 2017-02-02 18:55:23 UTC (rev 211573)
@@ -1,3 +1,62 @@
+2017-02-02 David Kilzer <[email protected]>
+
+ Clean up accessibility & animations tests to stop calling testRunner.waitUntilDone() twice
+ <https://webkit.org/b/167598>
+
+ Reviewed by Alexey Proskuryakov.
+
+ * accessibility/frame-disconnect-textmarker-cache-crash.html:
+ * accessibility/loading-iframe-sends-notification.html:
+ * accessibility/mac/combobox-activedescendant-notifications.html:
+ * accessibility/mac/ordered-textmarker-crash.html:
+ * accessibility/mac/stale-textmarker-crash.html:
+ * accessibility/notification-listeners.html:
+ * accessibility/scroll-to-global-point-iframe-nested.html:
+ * accessibility/scroll-to-global-point-iframe.html:
+ * accessibility/scroll-to-make-visible-iframe.html:
+ * accessibility/svg-element-press.html:
+ - Remove call to testRunner.waitUntilDone() since
+ window.jsTestIsAsync is set to true, and thus waitUntilDone()
+ is called from either js-test.js or js-test-post.js.
+
+ * animations/animation-delay-changed.html:
+ * animations/change-keyframes-name.html:
+ * animations/font-variations/font-variation-settings-order.html:
+ * animations/font-variations/font-variation-settings-unlike.html:
+ * animations/font-variations/font-variation-settings.html:
+ * animations/longhand-timing-function.html:
+ * animations/transition-and-animation-3.html:
+ * animations/unanimated-style.html:
+ - Remove call to testRunner.waitUntilDone() since that's moved
+ into animation-test-helpers.js.
+
+ * animations/resources/animation-test-helpers.js:
+ (runAnimationTest): Call testRunner.waitUntilDone() when this
+ script resource is included instead of when runAnimationTest()
+ is called since runAnimationTest() expects it to be set anyway.
+
+ * animations/animation-direction-reverse-fill-mode-hardware.html:
+ * animations/animation-direction-reverse-fill-mode.html:
+ * animations/animation-hit-test-transform.html:
+ * animations/animation-hit-test.html:
+ * animations/animation-internals-api-multiple-keyframes.html:
+ * animations/animation-internals-api.html:
+ * animations/change-transform-style-during-animation.html:
+ * animations/keyframes-iteration-count-non-integer.html:
+ - Remove call to testRunner.waitUntilDone() since that now
+ happens when loading animation-test-helpers.js. These tests
+ don't currently call runAnimationTest(), but they manage their
+ own state by calling testRunner.notifyDone() themselves.
+
+ * animations/crash-on-removing-animation.html:
+ * animations/resources/crash-on-removing-animation-window.html: Copied from LayoutTests/animations/crash-on-removing-animation.html.
+ - Split this test into a main resource and a window resource.
+ Previously testRunner.waitUntilDone() was being called twice
+ when js-test-post.js was loaded in the main window and then
+ loaded a second time when the window was opened. The new
+ resource file doesn't load either js-test-pre.js or
+ js-test-post.js, avoiding the duplicate call.
+
2017-02-02 Antti Koivisto <[email protected]>
Column progression wrong after enabling pagination on RTL document
Modified: trunk/LayoutTests/accessibility/frame-disconnect-textmarker-cache-crash.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/frame-disconnect-textmarker-cache-crash.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/frame-disconnect-textmarker-cache-crash.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -76,8 +76,6 @@
if (window.accessibilityController) {
window.jsTestIsAsync = true;
- if (window.testRunner)
- testRunner.waitUntilDone();
}
</script>
Modified: trunk/LayoutTests/accessibility/loading-iframe-sends-notification.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/loading-iframe-sends-notification.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/loading-iframe-sends-notification.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -19,9 +19,6 @@
<script>
description("This tests that when an iframe finishes loading, it sends a notification.");
- if (window.testRunner)
- testRunner.waitUntilDone();
-
window.jsTestIsAsync = true;
// Recursively search the entire accessibility tree starting at the given
Modified: trunk/LayoutTests/accessibility/mac/combobox-activedescendant-notifications.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/mac/combobox-activedescendant-notifications.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/mac/combobox-activedescendant-notifications.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -20,7 +20,6 @@
if (window.testRunner && window.accessibilityController) {
jsTestIsAsync = true;
- testRunner.waitUntilDone();
document.getElementById("combo").focus();
var combo = accessibilityController.accessibleElementById("combo");
Modified: trunk/LayoutTests/accessibility/mac/ordered-textmarker-crash.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/mac/ordered-textmarker-crash.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/mac/ordered-textmarker-crash.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -16,7 +16,6 @@
description("This tests that comparing text markers that have no common tree scope won't crash");
if (window.accessibilityController && window.testRunner) {
- window.testRunner.waitUntilDone();
window.jsTestIsAsync = true;
}
Modified: trunk/LayoutTests/accessibility/mac/stale-textmarker-crash.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/mac/stale-textmarker-crash.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/mac/stale-textmarker-crash.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -18,7 +18,6 @@
var cachedMarker1 = 0;
var cachedMarker2 = 0;
if (window.accessibilityController && window.testRunner) {
- window.testRunner.waitUntilDone();
window.jsTestIsAsync = true;
}
Modified: trunk/LayoutTests/accessibility/notification-listeners.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/notification-listeners.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/notification-listeners.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -16,9 +16,6 @@
description("This tests that a notification listener on an element only listens to that one element, and that a global notification listener listens to all notifications.");
function runTest() {
- if (window.testRunner)
- testRunner.waitUntilDone();
-
window.jsTestIsAsync = true;
window.selectNotificationCount = 0;
Modified: trunk/LayoutTests/accessibility/scroll-to-global-point-iframe-nested.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/scroll-to-global-point-iframe-nested.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/scroll-to-global-point-iframe-nested.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -26,9 +26,6 @@
<script>
description("Tests that scrolling to move an element to a specific point successfully scrolls both an iframe and a div with overflow.");
-if (window.testRunner)
- testRunner.waitUntilDone();
-
window.jsTestIsAsync = true;
function runTest() {
Modified: trunk/LayoutTests/accessibility/scroll-to-global-point-iframe.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/scroll-to-global-point-iframe.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/scroll-to-global-point-iframe.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -23,9 +23,6 @@
<script>
description("Tests that scrolling to move an element to a specific point successfully scrolls an iframe.");
-if (window.testRunner)
- testRunner.waitUntilDone();
-
window.jsTestIsAsync = true;
function runTest() {
Modified: trunk/LayoutTests/accessibility/scroll-to-make-visible-iframe.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/scroll-to-make-visible-iframe.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/scroll-to-make-visible-iframe.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -13,9 +13,6 @@
<script>
description("Tests that scrolling to make an element visible successfully scrolls an iframe.");
-if (window.testRunner)
- testRunner.waitUntilDone();
-
window.jsTestIsAsync = true;
function runTest() {
Modified: trunk/LayoutTests/accessibility/svg-element-press.html (211572 => 211573)
--- trunk/LayoutTests/accessibility/svg-element-press.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/accessibility/svg-element-press.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -19,6 +19,7 @@
<script>
window.jsTestIsAsync = true;
+
description("This tests that AXPress works on SVG elements");
function svgClicked() {
@@ -26,9 +27,6 @@
finishJSTest();
}
- if (window.testRunner)
- testRunner.waitUntilDone();
-
if (window.accessibilityController) {
var svg = accessibilityController.accessibleElementById("svg");
svg.press();
Modified: trunk/LayoutTests/animations/animation-delay-changed.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-delay-changed.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-delay-changed.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -40,9 +40,6 @@
</style>
<script src=""
<script>
- if (window.testRunner) {
- testRunner.waitUntilDone();
- }
window._onload_ = function() {
document.querySelector('#box1').classList.add('move1');
// Start the animation on box2 after 500ms
Modified: trunk/LayoutTests/animations/animation-direction-reverse-fill-mode-hardware.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-direction-reverse-fill-mode-hardware.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-direction-reverse-fill-mode-hardware.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -43,10 +43,8 @@
];
var result = "";
- if (window.testRunner) {
+ if (window.testRunner)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
- }
function animationEnded(event) {
if (++animsFinished == numAnims) {
Modified: trunk/LayoutTests/animations/animation-direction-reverse-fill-mode.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-direction-reverse-fill-mode.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-direction-reverse-fill-mode.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -56,10 +56,8 @@
];
var result = "";
- if (window.testRunner) {
+ if (window.testRunner)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
- }
function animationEnded(event) {
if (++animsFinished == numAnims) {
Modified: trunk/LayoutTests/animations/animation-hit-test-transform.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-hit-test-transform.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-hit-test-transform.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -74,10 +74,8 @@
function startTest()
{
- if (window.testRunner) {
+ if (window.testRunner)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
- }
document.getElementById("target").style.webkitAnimationName = "anim";
waitForAnimationToStart(document.getElementById('target'), doTest);
Modified: trunk/LayoutTests/animations/animation-hit-test.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-hit-test.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-hit-test.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -74,10 +74,8 @@
function startTest()
{
- if (window.testRunner) {
+ if (window.testRunner)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
- }
document.getElementById("target").style.webkitAnimationName = "anim";
waitForAnimationToStart(document.getElementById('target'), doTest);
Modified: trunk/LayoutTests/animations/animation-internals-api-multiple-keyframes.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-internals-api-multiple-keyframes.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-internals-api-multiple-keyframes.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -23,10 +23,8 @@
<script src=""
<script>
- if (window.testRunner) {
- testRunner.waitUntilDone();
- testRunner.dumpAsText();
- }
+ if (window.testRunner)
+ testRunner.dumpAsText();
function animationStarted()
{
Modified: trunk/LayoutTests/animations/animation-internals-api.html (211572 => 211573)
--- trunk/LayoutTests/animations/animation-internals-api.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/animation-internals-api.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -25,10 +25,8 @@
<script src=""
<script>
- if (window.testRunner) {
- testRunner.waitUntilDone();
+ if (window.testRunner)
testRunner.dumpAsText();
- }
function animationStarted()
{
Modified: trunk/LayoutTests/animations/change-keyframes-name.html (211572 => 211573)
--- trunk/LayoutTests/animations/change-keyframes-name.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/change-keyframes-name.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -59,7 +59,6 @@
{
if (window.testRunner) {
testRunner.dumpAsText();
- testRunner.waitUntilDone();
var box = document.getElementById('box');
if (internals.pauseAnimationAtTimeOnElement("bar", 0.5, box))
document.getElementById("pre-result").innerHTML = "FAIL: animation is running";
Modified: trunk/LayoutTests/animations/change-transform-style-during-animation.html (211572 => 211573)
--- trunk/LayoutTests/animations/change-transform-style-during-animation.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/change-transform-style-during-animation.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -37,10 +37,8 @@
<script src=""
<script>
- if (window.testRunner) {
+ if (window.testRunner)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
- }
function animationDone()
{
Modified: trunk/LayoutTests/animations/crash-on-removing-animation.html (211572 => 211573)
--- trunk/LayoutTests/animations/crash-on-removing-animation.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/crash-on-removing-animation.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -6,28 +6,10 @@
var successfullyParsed = false;
window.jsTestIsAsync = true;
- function tryToCrash() {
- var div = document.getElementById("test");
- div.style.webkitTransform = "translateY(1px)";
- div.style.webkitTransition = "1s ease-in-out";
- setTimeout(function() {
- div.style.webkitTransform = "none";
- div.style.webkitTransition = "none";
- setTimeout(function() {
- window.close();
- window.opener.finishJSTest();
- }, 0);
- }, 0);
- }
-
function setup() {
if (window.testRunner) {
- if (location.href.indexOf("auxillary") != -1) {
- setTimeout(tryToCrash, 0);
- } else {
- testRunner.setCanOpenWindows();
- window.open("crash-on-removing-animation.html#auxillary");
- }
+ testRunner.setCanOpenWindows();
+ window.open("resources/crash-on-removing-animation-window.html");
} else {
document.write("This test must be run in DRT/WKTR.");
}
Modified: trunk/LayoutTests/animations/font-variations/font-variation-settings-order.html (211572 => 211573)
--- trunk/LayoutTests/animations/font-variations/font-variation-settings-order.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/font-variations/font-variation-settings-order.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -35,10 +35,6 @@
["TheAnimation", 2.0, "box", "font-variation-settings", "'wdth' 766.6666, 'hght' 666.6666", 5],
];
-if (window.testRunner) {
- testRunner.waitUntilDone();
-}
-
var promises = [];
document.fonts.forEach(function(f) {
Modified: trunk/LayoutTests/animations/font-variations/font-variation-settings-unlike.html (211572 => 211573)
--- trunk/LayoutTests/animations/font-variations/font-variation-settings-unlike.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/font-variations/font-variation-settings-unlike.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -35,10 +35,6 @@
["TheAnimation", 2.0, "box", "font-variation-settings", "normal", 5],
];
-if (window.testRunner) {
- testRunner.waitUntilDone();
-}
-
var promises = [];
document.fonts.forEach(function(f) {
Modified: trunk/LayoutTests/animations/font-variations/font-variation-settings.html (211572 => 211573)
--- trunk/LayoutTests/animations/font-variations/font-variation-settings.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/font-variations/font-variation-settings.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -35,10 +35,6 @@
["TheAnimation", 2.0, "box", "font-variation-settings", "'wdth' 733.3333", 5],
];
-if (window.testRunner) {
- testRunner.waitUntilDone();
-}
-
var promises = [];
document.fonts.forEach(function(f) {
Modified: trunk/LayoutTests/animations/keyframes-iteration-count-non-integer.html (211572 => 211573)
--- trunk/LayoutTests/animations/keyframes-iteration-count-non-integer.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/keyframes-iteration-count-non-integer.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -30,10 +30,8 @@
<script src="" type="text/_javascript_" charset="utf-8"></script>
<script type="text/_javascript_" charset="utf-8">
- if (window.testRunner) {
+ if (window.testRunner)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
- }
document.addEventListener("webkitAnimationEnd", function(event){
var result;
Modified: trunk/LayoutTests/animations/longhand-timing-function.html (211572 => 211573)
--- trunk/LayoutTests/animations/longhand-timing-function.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/longhand-timing-function.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -26,14 +26,11 @@
</style>
<script src="" type="text/_javascript_" charset="utf-8"></script>
<script type="text/_javascript_" charset="utf-8">
- if (window.testRunner)
- testRunner.waitUntilDone();
-
- const expectedValues = [
+ const expectedValues = [
// [animation-name, time, element-id, property, expected-value, tolerance]
["move", 0.5, "control", "left", 200, 10],
["move", 0.5, "test", "left", 200, 10],
- ];
+ ];
function setupTest()
{
Modified: trunk/LayoutTests/animations/resources/animation-test-helpers.js (211572 => 211573)
--- trunk/LayoutTests/animations/resources/animation-test-helpers.js 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/resources/animation-test-helpers.js 2017-02-02 18:55:23 UTC (rev 211573)
@@ -533,6 +533,9 @@
var result = "";
var hasPauseAnimationAPI;
+if (window.testRunner)
+ testRunner.waitUntilDone();
+
function runAnimationTest(expected, startCallback, event, disablePauseAnimationAPI, doPixelTest, finishCallback)
{
hasPauseAnimationAPI = 'internals' in window;
@@ -542,7 +545,6 @@
if (window.testRunner) {
if (!doPixelTest)
testRunner.dumpAsText();
- testRunner.waitUntilDone();
}
if (!expected)
Copied: trunk/LayoutTests/animations/resources/crash-on-removing-animation-window.html (from rev 211572, trunk/LayoutTests/animations/crash-on-removing-animation.html) (0 => 211573)
--- trunk/LayoutTests/animations/resources/crash-on-removing-animation-window.html (rev 0)
+++ trunk/LayoutTests/animations/resources/crash-on-removing-animation-window.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -0,0 +1,42 @@
+<html>
+
+<head>
+ <script>
+ function tryToCrash() {
+ var div = document.getElementById("test");
+ div.style.webkitTransform = "translateY(1px)";
+ div.style.webkitTransition = "1s ease-in-out";
+ setTimeout(function() {
+ div.style.webkitTransform = "none";
+ div.style.webkitTransition = "none";
+ setTimeout(function() {
+ window.close();
+ window.opener.finishJSTest();
+ }, 0);
+ }, 0);
+ }
+
+ function setup() {
+ if (window.testRunner) {
+ setTimeout(tryToCrash, 0);
+ } else {
+ document.write("This test must be run in DRT/WKTR.");
+ }
+ }
+ </script>
+
+ <style>
+ #test {
+ background-color: blue;
+ width: 10px;
+ height: 10px;
+ }
+ </style>
+<head>
+
+<body _onload_="setup()">
+ <div id="test"></div>
+ <p>If you are reading this, we managed to avoid crashing!</p>
+</body>
+
+</html>
Modified: trunk/LayoutTests/animations/transition-and-animation-3.html (211572 => 211573)
--- trunk/LayoutTests/animations/transition-and-animation-3.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/transition-and-animation-3.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -38,9 +38,6 @@
<script src="" type="text/_javascript_" charset="utf-8"></script>
<script type="text/_javascript_" charset="utf-8">
- if (window.testRunner)
- testRunner.waitUntilDone();
-
const expectedValues = [
// [animation-name, time, element-id, property, expected-value, tolerance]
[null, 0.2, "test", "left", 100, 10],
Modified: trunk/LayoutTests/animations/unanimated-style.html (211572 => 211573)
--- trunk/LayoutTests/animations/unanimated-style.html 2017-02-02 18:42:02 UTC (rev 211572)
+++ trunk/LayoutTests/animations/unanimated-style.html 2017-02-02 18:55:23 UTC (rev 211573)
@@ -31,9 +31,6 @@
<script src="" type="text/_javascript_" charset="utf-8"></script>
<script type="text/_javascript_" charset="utf-8">
- if (window.testRunner)
- testRunner.waitUntilDone();
-
const expectedValues = [
// [animation-name, time, element-id, property, expected-value, tolerance]
["move", 0.5, "test", "left", 450, 8],