LayoutTest media/modern-media-controls/media-controller/media-controller-resize.html...
authorgraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Mar 2017 05:31:57 +0000 (05:31 +0000)
committergraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 2 Mar 2017 05:31:57 +0000 (05:31 +0000)
https://bugs.webkit.org/show_bug.cgi?id=168378
<rdar://problem/30799326>

Reviewed by Simon Fraser.

Use asynchronous assertions to improve robustness. Since this test should no longer be flaky, remove it
from the list of flaky tests.

* media/modern-media-controls/media-controller/media-controller-resize-expected.txt:
* media/modern-media-controls/media-controller/media-controller-resize.html:
* platform/mac-wk1/TestExpectations:

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

LayoutTests/ChangeLog
LayoutTests/media/modern-media-controls/media-controller/media-controller-resize-expected.txt
LayoutTests/media/modern-media-controls/media-controller/media-controller-resize.html
LayoutTests/platform/mac-wk1/TestExpectations

index 2d4d385..3e7f5eb 100644 (file)
@@ -1,5 +1,20 @@
 2017-03-01  Antoine Quint  <graouts@apple.com>
 
+        LayoutTest media/modern-media-controls/media-controller/media-controller-resize.html is a flaky failure
+        https://bugs.webkit.org/show_bug.cgi?id=168378
+        <rdar://problem/30799326>
+
+        Reviewed by Simon Fraser.
+
+        Use asynchronous assertions to improve robustness. Since this test should no longer be flaky, remove it
+        from the list of flaky tests.
+
+        * media/modern-media-controls/media-controller/media-controller-resize-expected.txt:
+        * media/modern-media-controls/media-controller/media-controller-resize.html:
+        * platform/mac-wk1/TestExpectations:
+
+2017-03-01  Antoine Quint  <graouts@apple.com>
+
         [mac-wk1] LayoutTest media/modern-media-controls/tracks-button/tracks-button.html is a flaky timeout
         https://bugs.webkit.org/show_bug.cgi?id=168476
         <rdar://problem/30799198>
index d7f67df..236f4dd 100644 (file)
@@ -8,10 +8,8 @@ PASS mediaControls.style.width is "320px"
 PASS mediaControls.style.height is "240px"
 
 Resizing to 400x300
-
-Shadow root received a resize event
-PASS mediaControls.style.width is "400px"
-PASS mediaControls.style.height is "300px"
+PASS mediaControls.style.width became "400px"
+PASS mediaControls.style.height became "300px"
 
 PASS successfullyParsed is true
 
index e9a4926..6aba513 100644 (file)
@@ -16,24 +16,17 @@ debug("Checking initial size");
 shouldBeEqualToString("mediaControls.style.width", "320px");
 shouldBeEqualToString("mediaControls.style.height", "240px");
 
-window.requestAnimationFrame(() => {
-    shadowRoot.addEventListener("resize", () => {
-        window.requestAnimationFrame(() => {
-            debug("");
-            debug("Shadow root received a resize event");
-            shouldBeEqualToString("mediaControls.style.width", "400px");
-            shouldBeEqualToString("mediaControls.style.height", "300px");
-
-            debug("");
-            media.remove();
-            finishJSTest();
-        });
+debug("");
+debug("Resizing to 400x300");
+media.style.width = "400px";
+media.style.height = "300px";
+
+shouldBecomeEqualToString("mediaControls.style.width", "400px", () => {
+    shouldBecomeEqualToString("mediaControls.style.height", "300px", () => {
+        debug("");
+        media.remove();
+        finishJSTest();
     });
-
-    debug("");
-    debug("Resizing to 400x300");
-    media.style.width = "400px";
-    media.style.height = "300px";
 });
 
 </script>
index a0d63f7..7e87507 100644 (file)
@@ -320,5 +320,3 @@ media/track/track-cues-enter-exit.html [ Pass Crash ]
 webkit.org/b/167127 pointer-lock/locked-element-removed-from-dom.html
 
 webkit.org/b/167857 pageoverlay/overlay-remove-reinsert-view.html [ Skip ]
-
-webkit.org/b/168378 media/modern-media-controls/media-controller/media-controller-resize.html [ Pass Failure ]