Early Exit Failing Mac Fling Tests on Viz

There are two remaining Mac Fling tests which fail under Viz. Work is
ongoing to land a fix, but there was flakiness if the resolution.

This change updates the failing tests to exit early when it is Viz on
Mac. This will unblock removing our filter files.

TEST=BrowserSideFlingBrowserTest.TouchpadFling
BrowserSideFlingBrowserTest.TouchscreenFling

Bug: 842325
Change-Id: I67e7c6165d821c9df4907ebf8803fe22fbdf1663
Reviewed-on: https://chromium-review.googlesource.com/1151392
Reviewed-by: ccameron <ccameron@chromium.org>
Commit-Queue: Jonathan Ross <jonross@chromium.org>
Cr-Commit-Position: refs/heads/master@{#578362}
diff --git a/content/browser/renderer_host/input/fling_browsertest.cc b/content/browser/renderer_host/input/fling_browsertest.cc
index b8371dc..c952871f 100644
--- a/content/browser/renderer_host/input/fling_browsertest.cc
+++ b/content/browser/renderer_host/input/fling_browsertest.cc
@@ -2,7 +2,9 @@
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
 
+#include "base/feature_list.h"
 #include "build/build_config.h"
+#include "components/viz/common/features.h"
 #include "content/browser/renderer_host/input/synthetic_smooth_scroll_gesture.h"
 #include "content/browser/web_contents/web_contents_impl.h"
 #include "content/public/test/browser_test_utils.h"
@@ -107,6 +109,13 @@
 };
 
 IN_PROC_BROWSER_TEST_F(BrowserSideFlingBrowserTest, TouchscreenFling) {
+#if defined(OS_MACOSX)
+  // TODO(jonross): Re-enable once fling on Mac works with Viz.
+  // https://crbug.com/842325
+  if (base::FeatureList::IsEnabled(features::kVizDisplayCompositor))
+    return;
+#endif  // defined(OS_MACOSX)
+
   LoadURL(kBrowserFlingDataURL);
 
   // Send a GSB to start scrolling sequence.
@@ -140,6 +149,13 @@
 }
 
 IN_PROC_BROWSER_TEST_F(BrowserSideFlingBrowserTest, TouchpadFling) {
+#if defined(OS_MACOSX)
+  // TODO(jonross): Re-enable once fling on Mac works with Viz.
+  // https://crbug.com/842325
+  if (base::FeatureList::IsEnabled(features::kVizDisplayCompositor))
+    return;
+#endif  // defined(OS_MACOSX)
+
   LoadURL(kBrowserFlingDataURL);
 
   // Send a wheel event to start scrolling sequence.