Unreviewed, rolling out r231763.
authorryanhaddad@apple.com <ryanhaddad@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 15 May 2018 17:20:40 +0000 (17:20 +0000)
committerryanhaddad@apple.com <ryanhaddad@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 15 May 2018 17:20:40 +0000 (17:20 +0000)
The test added with this change is failing an assertion.

Reverted changeset:

"NSEvent event trackers don't work from WebKitTestRunner"
https://bugs.webkit.org/show_bug.cgi?id=185383
https://trac.webkit.org/changeset/231763

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

LayoutTests/ChangeLog
LayoutTests/swipe/wheel-event-initiated-back-navigation-expected.txt [deleted file]
LayoutTests/swipe/wheel-event-initiated-back-navigation.html [deleted file]
Tools/ChangeLog
Tools/WebKitTestRunner/mac/EventSenderProxy.mm

index c9976cb..543aa8b 100644 (file)
@@ -1,3 +1,15 @@
+2018-05-15  Ryan Haddad  <ryanhaddad@apple.com>
+
+        Unreviewed, rolling out r231763.
+
+        The test added with this change is failing an assertion.
+
+        Reverted changeset:
+
+        "NSEvent event trackers don't work from WebKitTestRunner"
+        https://bugs.webkit.org/show_bug.cgi?id=185383
+        https://trac.webkit.org/changeset/231763
+
 2018-05-15  Aditya Keerthi  <akeerthi@apple.com>
 
         Add test to verify behavior of -webkit-text-fill-color when inherited.
diff --git a/LayoutTests/swipe/wheel-event-initiated-back-navigation-expected.txt b/LayoutTests/swipe/wheel-event-initiated-back-navigation-expected.txt
deleted file mode 100644 (file)
index 4339457..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-This is a swipe navigation test.
-
-PASS: mouseWheel caused navigation
-PASS: navigated back to page1
-
diff --git a/LayoutTests/swipe/wheel-event-initiated-back-navigation.html b/LayoutTests/swipe/wheel-event-initiated-back-navigation.html
deleted file mode 100644 (file)
index c612486..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-<html>
-<head>
-<script>
-
-function logResult(s) {
-    document.getElementById('result').textContent += s + "\n";
-}
-
-function backSwipe()
-{
-    var divTarget = document.getElementById('content');
-    var documentBounds = divTarget.getBoundingClientRect();
-    
-    eventSender.mouseMoveTo(documentBounds.left + 10, documentBounds.top + 10);
-    eventSender.mouseScrollByWithWheelAndMomentumPhases(100, 0, 'began', 'none');
-    eventSender.mouseScrollByWithWheelAndMomentumPhases(100, 0, 'changed', 'none');
-    eventSender.mouseScrollByWithWheelAndMomentumPhases(100, 0, 'changed', 'none');
-    eventSender.mouseScrollByWithWheelAndMomentumPhases(100, 0, 'ended', 'none');
-}
-
-function startTest()
-{
-    if (!window.eventSender) {
-        logResult('This test must be run in DumpRenderTree/WebKitTestRunner (no eventSender)');
-        return;
-    }
-
-    if (!window.testRunner) {
-        logResult('This test must be run in DumpRenderTree/WebKitTestRunner (no testRunner)');
-        return;
-    }
-
-    testRunner.dumpAsText();
-    testRunner.waitUntilDone();
-    testRunner.overridePreference("WebKitUsesPageCachePreferenceKey", 1);
-    testRunner.setNavigationGesturesEnabled(true);
-
-    window.onpopstate = function(event) {
-        logResult('PASS: mouseWheel caused navigation');
-        if (event.state.name == "page1") {
-            logResult('PASS: navigated back to ' + event.state.name);
-        } else {
-            logResult('FAILED: navigated back to ' + event.state.name);
-        }
-        testRunner.notifyDone();
-    };
-
-    var stateObj = { name: "page1" };
-    history.replaceState(stateObj, "page1", "");
-
-    var stateObj = { name: "page2" };
-    history.pushState(stateObj, "page2", "");
-
-    backSwipe();
-}
-
-window.addEventListener('load', startTest, false);
-
-</script>
-</head>
-<body id="content">
-
-<h1>This is a swipe navigation test.</h1>
-
-<pre id="result"></pre>
-
-</body>
-</html>
\ No newline at end of file
index 4267070..a043f4b 100644 (file)
@@ -1,3 +1,15 @@
+2018-05-15  Ryan Haddad  <ryanhaddad@apple.com>
+
+        Unreviewed, rolling out r231763.
+
+        The test added with this change is failing an assertion.
+
+        Reverted changeset:
+
+        "NSEvent event trackers don't work from WebKitTestRunner"
+        https://bugs.webkit.org/show_bug.cgi?id=185383
+        https://trac.webkit.org/changeset/231763
+
 2018-05-15  David Kilzer  <ddkilzer@apple.com>
 
         TestWebKitAPI: Fix warnings found by new clang compiler
index da25e4f..790f635 100644 (file)
@@ -43,7 +43,6 @@
 @end
 
 @interface NSEvent (ForTestRunner)
-+ (NSEvent *)_sendEventToObservers:(NSEvent *)event;
 - (void)_postDelayed;
 @end
 
@@ -877,7 +876,6 @@ void EventSenderProxy::mouseScrollByWithWheelAndMomentumPhases(int x, int y, int
     // Our event should have the correct settings:
     if (NSView *targetView = [m_testController->mainWebView()->platformView() hitTest:[event locationInWindow]]) {
         [NSApp _setCurrentEvent:event];
-        event = [NSEvent _sendEventToObservers:event];
         [targetView scrollWheel:event];
         [NSApp _setCurrentEvent:nil];
     } else {