Commit f2bf009a authored by Sahel Sharify's avatar Sahel Sharify Committed by Commit Bot

Disable wheel scroll latching in failing content_browsertests.

I cannot reproduce the test failures on my local official windows build,
in this cl I force wheel scroll latching to be disabled in the tests to
see if it changes the test results on Win official or not.

Bug: 800822
Change-Id: Ife07a29617ca5e0142e75f926967685cb61e2a08
Reviewed-on: https://chromium-review.googlesource.com/895842Reviewed-by: default avatarJames MacLean <wjmaclean@chromium.org>
Reviewed-by: default avatarNasko Oskov <nasko@chromium.org>
Commit-Queue: Sahel Sharifymoghaddam <sahel@chromium.org>
Cr-Commit-Position: refs/heads/master@{#533347}
parent 901e3dcb
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
#include "base/feature_list.h" #include "base/feature_list.h"
#include "base/json/json_reader.h" #include "base/json/json_reader.h"
#include "base/test/bind_test_util.h" #include "base/test/bind_test_util.h"
#include "base/test/scoped_feature_list.h"
#include "base/test/test_timeouts.h" #include "base/test/test_timeouts.h"
#include "build/build_config.h" #include "build/build_config.h"
#include "components/viz/common/switches.h" #include "components/viz/common/switches.h"
...@@ -1634,12 +1635,17 @@ class SitePerProcessMouseWheelHitTestBrowserTest ...@@ -1634,12 +1635,17 @@ class SitePerProcessMouseWheelHitTestBrowserTest
EXPECT_EQ("\"scroll: 3\"", reply); EXPECT_EQ("\"scroll: 3\"", reply);
} }
protected:
base::test::ScopedFeatureList feature_list_;
private: private:
RenderWidgetHostViewAura* rwhv_root_; RenderWidgetHostViewAura* rwhv_root_;
}; };
IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest, IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest,
SubframeWheelEventsOnMainThread) { SubframeWheelEventsOnMainThread) {
feature_list_.InitWithFeatures({}, {features::kTouchpadAndWheelScrollLatching,
features::kAsyncWheelEvents});
GURL main_url(embedded_test_server()->GetURL( GURL main_url(embedded_test_server()->GetURL(
"/frame_tree/page_with_positioned_nested_frames.html")); "/frame_tree/page_with_positioned_nested_frames.html"));
EXPECT_TRUE(NavigateToURL(shell(), main_url)); EXPECT_TRUE(NavigateToURL(shell(), main_url));
...@@ -1655,6 +1661,8 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest, ...@@ -1655,6 +1661,8 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest,
// surface information required for event hit testing is ready. // surface information required for event hit testing is ready.
RenderWidgetHostViewBase* child_rwhv = static_cast<RenderWidgetHostViewBase*>( RenderWidgetHostViewBase* child_rwhv = static_cast<RenderWidgetHostViewBase*>(
root->child_at(0)->current_frame_host()->GetView()); root->child_at(0)->current_frame_host()->GetView());
EXPECT_FALSE(child_rwhv->wheel_scroll_latching_enabled());
WaitForChildFrameSurfaceReady(root->child_at(0)->current_frame_host()); WaitForChildFrameSurfaceReady(root->child_at(0)->current_frame_host());
content::RenderFrameHostImpl* child = root->child_at(0)->current_frame_host(); content::RenderFrameHostImpl* child = root->child_at(0)->current_frame_host();
...@@ -1670,6 +1678,8 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest, ...@@ -1670,6 +1678,8 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest,
// the same page loaded in the mainframe. // the same page loaded in the mainframe.
IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest, IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest,
MainframeWheelEventsOnMainThread) { MainframeWheelEventsOnMainThread) {
feature_list_.InitWithFeatures({}, {features::kTouchpadAndWheelScrollLatching,
features::kAsyncWheelEvents});
GURL main_url( GURL main_url(
embedded_test_server()->GetURL("/page_with_scrollable_div.html")); embedded_test_server()->GetURL("/page_with_scrollable_div.html"));
EXPECT_TRUE(NavigateToURL(shell(), main_url)); EXPECT_TRUE(NavigateToURL(shell(), main_url));
...@@ -1678,6 +1688,9 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest, ...@@ -1678,6 +1688,9 @@ IN_PROC_BROWSER_TEST_F(SitePerProcessMouseWheelHitTestBrowserTest,
content::RenderFrameHostImpl* rfhi = root->current_frame_host(); content::RenderFrameHostImpl* rfhi = root->current_frame_host();
SetupWheelAndScrollHandlers(rfhi); SetupWheelAndScrollHandlers(rfhi);
EXPECT_FALSE(
rfhi->GetRenderWidgetHost()->GetView()->wheel_scroll_latching_enabled());
gfx::Point pos(10, 10); gfx::Point pos(10, 10);
RunTest(pos, rfhi->GetRenderWidgetHost()->GetView()); RunTest(pos, rfhi->GetRenderWidgetHost()->GetView());
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment