RESOLVED FIXED 164764
Hard to write reliable UIScriptController scrollingTreeAsText tests
https://bugs.webkit.org/show_bug.cgi?id=164764
Summary Hard to write reliable UIScriptController scrollingTreeAsText tests
Simon Fraser (smfr)
Reported 2016-11-14 20:44:09 PST
It's very hard to know when the UI process has received a scrolling tree update, so scrollingTreeAsText tests are flakey.
Attachments
Patch (1.80 KB, patch)
2016-11-16 15:05 PST, Simon Fraser (smfr)
wenson_hsieh: review+
Simon Fraser (smfr)
Comment 1 2016-11-14 21:15:39 PST
Maybe need this: diff --git a/Tools/WebKitTestRunner/ios/TestControllerIOS.mm b/Tools/WebKitTestRunner/ios/TestControllerIOS.mm index 03454a5b5d4847e015a142a19b31920141373bb4..452c410c8379b70c6512dad2c0fd0146311afbda 100644 --- a/Tools/WebKitTestRunner/ios/TestControllerIOS.mm +++ b/Tools/WebKitTestRunner/ios/TestControllerIOS.mm @@ -28,6 +28,7 @@ #import "PlatformWebView.h" #import "TestInvocation.h" +#import "TestRunnerWKWebView.h" #import <Foundation/Foundation.h> #import <UIKit/UIKit.h> #import <WebKit/WKPreferencesRefPrivate.h> @@ -83,6 +84,12 @@ void TestController::platformResetPreferencesToConsistentValues() void TestController::platformResetStateToConsistentValues() { cocoaResetStateToConsistentValues(); + + if (PlatformWebView* webView = mainWebView()) { + UIScrollView *scrollView = webView->platformView().scrollView; + [scrollView setZoomScale:1 animated:NO]; + [scrollView setContentOffset:CGPointZero]; + } } void TestController::platformConfigureViewForTest(const TestInvocation& test)
Simon Fraser (smfr)
Comment 2 2016-11-16 15:05:24 PST
Wenson Hsieh
Comment 3 2016-11-16 15:14:36 PST
Comment on attachment 294981 [details] Patch r=mews
Simon Fraser (smfr)
Comment 4 2016-11-16 15:17:34 PST
Note You need to log in before you can comment on or make changes to this bug.