REGRESSION: [ Mac wk2 ] tiled-drawing/scrolling/fast-scroll-select-latched-mainframe...
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Dec 2019 03:12:54 +0000 (03:12 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Dec 2019 03:12:54 +0000 (03:12 +0000)
https://bugs.webkit.org/show_bug.cgi?id=205363
<rdar://problem/58025488>

Reviewed by Wenson Hsieh.

Fix the test by waiting for rAF and avoid running checkForScroll more than once.

* platform/mac-wk2/TestExpectations:
* tiled-drawing/scrolling/fast-scroll-select-latched-mainframe.html:

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

LayoutTests/ChangeLog
LayoutTests/platform/mac-wk2/TestExpectations
LayoutTests/tiled-drawing/scrolling/fast-scroll-select-latched-mainframe.html

index edf8a11..ab0c9ad 100644 (file)
@@ -1,3 +1,16 @@
+2019-12-18  Ryosuke Niwa  <rniwa@webkit.org>
+
+        REGRESSION: [ Mac wk2 ] tiled-drawing/scrolling/fast-scroll-select-latched-mainframe.html is a flakey failure
+        https://bugs.webkit.org/show_bug.cgi?id=205363
+        <rdar://problem/58025488>
+
+        Reviewed by Wenson Hsieh.
+
+        Fix the test by waiting for rAF and avoid running checkForScroll more than once.
+
+        * platform/mac-wk2/TestExpectations:
+        * tiled-drawing/scrolling/fast-scroll-select-latched-mainframe.html:
+
 2019-12-18  Antoine Quint  <graouts@apple.com>
 
         Animations stop if new tab opened (and closed)
index c1e41a6..8c0b9e7 100644 (file)
@@ -659,8 +659,6 @@ webkit.org/b/171763 compositing/tiling/non-active-window-tiles-size.html [ Pass
 
 webkit.org/b/171837 [ Debug ] http/tests/security/storage-blocking-loosened-plugin.html [ Pass Failure ]
 
-webkit.org/b/171935 tiled-drawing/scrolling/fast-scroll-select-latched-mainframe.html [ Pass Failure ]
-
 webkit.org/b/171939 [ Sierra Release ] media/track/track-cue-rendering-on-resize.html [ Pass Timeout ]
 
 webkit.org/b/171947 [ Sierra Release ] transitions/extra-transition.html [ Pass Failure ]
index 63d951e..d4f780f 100644 (file)
@@ -47,8 +47,13 @@ function onPageScroll()
         checkForScroll();
 }
 
+let didCheckForScroll = false;
 function checkForScroll()
 {
+    if (didCheckForScroll)
+        return;
+    didCheckForScroll = true;
+
     // The select should not have scrolled at all.
     var pageScrollPositionAfter = document.scrollingElement.scrollTop;
     var selectScrollPositionAfter = selectTarget.scrollTop;
@@ -85,7 +90,9 @@ function scrollTest()
     eventSender.mouseScrollByWithWheelAndMomentumPhases(0, -1, 'none', 'begin');
     eventSender.mouseScrollByWithWheelAndMomentumPhases(0, -4, 'none', 'continue');
     eventSender.mouseScrollByWithWheelAndMomentumPhases(0, 0, 'none', 'end');
-    eventSender.callAfterScrollingCompletes(checkForScroll);
+    eventSender.callAfterScrollingCompletes(() => {
+        requestAnimationFrame(checkForScroll);
+    });
 
     // We should finish via the scroll event; this will fire in the case of failure when the page doesn't scroll.
 }