Modified: trunk/LayoutTests/ChangeLog (250780 => 250781)
--- trunk/LayoutTests/ChangeLog 2019-10-07 18:48:48 UTC (rev 250780)
+++ trunk/LayoutTests/ChangeLog 2019-10-07 18:57:27 UTC (rev 250781)
@@ -1,3 +1,20 @@
+2019-10-07 Antoine Quint <[email protected]>
+
+ [macOS WK2 Debug ] Flaky Test: animations/play-state-in-shorthand.html
+ https://bugs.webkit.org/show_bug.cgi?id=192501
+
+ Reviewed by Simon Fraser.
+
+ This test used to rely on timers to check the computed style at various animation times and also to check the "animation-play-state"
+ to "paused" via the "animation" shorthand CSS property. This was flaky by design since timers could not fire with high enough fidelity
+ to ensure the animation time matched the expectation. With the availability of the Web Animations API, we can simply use the "playState"
+ property on the Animation object reflecting the CSS animation to check that the change is accounted for.
+
+ * animations/play-state-in-shorthand-expected.txt:
+ * animations/play-state-in-shorthand.html:
+ * platform/ios-simulator-wk2/TestExpectations:
+ * platform/mac/TestExpectations:
+
2019-10-07 Dirk Schulze <[email protected]>
clip-path: <geometry-box> mapping incorrect
Modified: trunk/LayoutTests/animations/play-state-in-shorthand-expected.txt (250780 => 250781)
--- trunk/LayoutTests/animations/play-state-in-shorthand-expected.txt 2019-10-07 18:48:48 UTC (rev 250780)
+++ trunk/LayoutTests/animations/play-state-in-shorthand-expected.txt 2019-10-07 18:57:27 UTC (rev 250781)
@@ -1,4 +1,2 @@
-PASS - "transform" property for "box" element at 0.5s saw something close to: 1,0,0,1,75,0
-PASS - "transform" property for "box" element at 1s saw something close to: 1,0,0,1,150,0
-PASS - "transform" property for "box" element at 2.5s saw something close to: 1,0,0,1,150,0
-
+PASS - animation is running upon receiving animationstart event
+PASS - animation is paused after setting the animation-play-state property to paused through the shorthand
Modified: trunk/LayoutTests/animations/play-state-in-shorthand.html (250780 => 250781)
--- trunk/LayoutTests/animations/play-state-in-shorthand.html 2019-10-07 18:48:48 UTC (rev 250780)
+++ trunk/LayoutTests/animations/play-state-in-shorthand.html 2019-10-07 18:57:27 UTC (rev 250781)
@@ -25,31 +25,26 @@
to { transform: translateX(300px); }
}
</style>
- <script src="" type="text/_javascript_"></script>
- <script type="text/_javascript_">
- const expectedValues = [
- // [animation-name, time, element-id, property, expected-value, tolerance]
- ["move1", 0.5, "box", "transform", [1,0,0,1,75,0], 20],
- ["move1", 1.0, "box", "transform", [1,0,0,1,150,0], 20],
- ["move1", 2.5, "box", "transform", [1,0,0,1,150,0], 20],
- ];
+</head>
+<body>
+<div id="box"></div>
+<div id="result"></div>
+<script type="text/_javascript_">
- function pauseAnimation()
- {
- document.getElementById("box").classList.add('paused');
+ if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
}
- function setTimers()
- {
- setTimeout(pauseAnimation, 1000);
- }
+ document.getElementById("box").addEventListener("animationstart", event => {
+ const animation = event.target.getAnimations()[0];
+ result.innerHTML += `${animation.playState == "running" ? "PASS" : "FAIL"} - animation is running upon receiving animationstart event<br>`;
+ event.target.classList.add("paused");
+ result.innerHTML += `${animation.playState == "paused" ? "PASS" : "FAIL"} - animation is paused after setting the animation-play-state property to paused through the shorthand`;
- runAnimationTest(expectedValues, setTimers, null, true);
- </script>
-</head>
-<body>
-<div id="box"></div>
-<div id="result"></div>
-</div>
+ if (window.testRunner)
+ testRunner.notifyDone();
+ });
+</script>
</body>
</html>
Modified: trunk/LayoutTests/platform/ios-simulator-wk2/TestExpectations (250780 => 250781)
--- trunk/LayoutTests/platform/ios-simulator-wk2/TestExpectations 2019-10-07 18:48:48 UTC (rev 250780)
+++ trunk/LayoutTests/platform/ios-simulator-wk2/TestExpectations 2019-10-07 18:57:27 UTC (rev 250781)
@@ -80,8 +80,6 @@
webkit.org/b/197207 http/wpt/resource-timing/rt-resources-per-frame.html [ Pass Failure ]
-webkit.org/b/192501 animations/play-state-in-shorthand.html [ Pass Failure ]
-
webkit.org/b/182849 imported/w3c/web-platform-tests/xhr/event-upload-progress-crossorigin.htm [ Pass Failure ]
imported/w3c/web-platform-tests/IndexedDB/keypath-special-identifiers.htm [ Slow ]
Modified: trunk/LayoutTests/platform/mac/TestExpectations (250780 => 250781)
--- trunk/LayoutTests/platform/mac/TestExpectations 2019-10-07 18:48:48 UTC (rev 250780)
+++ trunk/LayoutTests/platform/mac/TestExpectations 2019-10-07 18:57:27 UTC (rev 250781)
@@ -1883,8 +1883,6 @@
imported/w3c/web-platform-tests/pointerevents/pointerlock/pointerevent_pointermove_in_pointerlock-manual.html [ Skip ]
imported/w3c/web-platform-tests/pointerevents/pointerlock/pointerevent_pointermove_on_chorded_mouse_button_when_locked-manual.html [ Skip ]
-webkit.org/b/192501 [ Debug ] animations/play-state-in-shorthand.html [ Pass Failure ]
-
webkit.org/b/197473 imported/w3c/web-platform-tests/resource-timing/resource-timing-level1.sub.html [ Pass Failure ]
webkit.org/b/136627 [ Mojave+ ] media/track/track-cue-rendering-vertical.html [ Failure ]