[mac] LayoutTest media/modern-media-controls/play-pause-button/play-pause-button...
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 11 Oct 2016 14:57:55 +0000 (14:57 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 11 Oct 2016 14:57:55 +0000 (14:57 +0000)
https://bugs.webkit.org/show_bug.cgi?id=163249

Patch by Antoine Quint <graouts@apple.com> on 2016-10-11
Reviewed by Antoine Quint.

Wait until all icon images are loaded before running the assertions. We can determine whether
a button's icon image is loaded by checking it's been sized.

* TestExpectations:
* media/modern-media-controls/play-pause-button/play-pause-button.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@207138 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/TestExpectations
LayoutTests/media/modern-media-controls/play-pause-button/play-pause-button.html

index a60c7e3..c9a45fd 100644 (file)
@@ -1,5 +1,18 @@
 2016-10-11  Antoine Quint  <graouts@apple.com>
 
+        [mac] LayoutTest media/modern-media-controls/play-pause-button/play-pause-button.html is a flaky failure
+        https://bugs.webkit.org/show_bug.cgi?id=163249
+
+        Reviewed by Antoine Quint.
+
+        Wait until all icon images are loaded before running the assertions. We can determine whether
+        a button's icon image is loaded by checking it's been sized.
+
+        * TestExpectations:
+        * media/modern-media-controls/play-pause-button/play-pause-button.html:
+
+2016-10-11  Antoine Quint  <graouts@apple.com>
+
         [mac] LayoutTest media/modern-media-controls/airplay-button/airplay-button.html is a flaky failure
         https://bugs.webkit.org/show_bug.cgi?id=163248
 
index 7bd471c..bae304a 100644 (file)
@@ -986,4 +986,3 @@ webkit.org/b/162414 imported/w3c/web-platform-tests/resource-timing/idlharness.h
 # Only iOS has implemented lettepress.
 fast/text/letterpress-different.html [ ImageOnlyFailure ]
 
-webkit.org/b/163249 media/modern-media-controls/play-pause-button/play-pause-button.html [ Failure ]
index 8d9643f..45b9b59 100644 (file)
@@ -41,6 +41,9 @@ iOSPauseButton.playing = true;
 
 scheduler.frameDidFire = function()
 {
+    if ([playButton, pauseButton, iOSPlayButton, iOSPauseButton, fullscreenPlayButton, fullscreenPauseButton].some(button => button.width == 0))
+        return;
+
     shouldBeTrue('playButton.element.style.webkitMaskImage.includes("macOS/play@")');
     shouldBeTrue('pauseButton.element.style.webkitMaskImage.includes("macOS/pause@")');
     shouldBeTrue('iOSPlayButton.element.style.webkitMaskImage.includes("iOS/play@")');