Commit 13e803b0 authored by Maksim Sisov's avatar Maksim Sisov Committed by Commit Bot

X11 and Ozone: disable X11 specific tests in views_unittests

Enabling use_x11 && use_ozone results in running X11-only tests
that cannot succeed for Wayland config. Thus, disable them
(as it was before we started to work on use_x11 && use_ozone
config) via checking for the feature flag instead of relaying
on GN. I acknowledge that this is wrong to do, but I'm going to
fix that as soon as use_x11 && use_ozone config is upstreamed.

-----

PS: Please note that this is a temp solution that will help to choose
between ozone and non-ozone X11 build. The switch that will be used
to choose the path is --enable-features=UseOzonePlatform. Once
non-Ozone X11 path is removed (hopefully by Q1 2021 depending on how
the finch trial goes), the wrapper will be removed.

Please also note that it's impossible to build use_x11 && use_ozone
without some hacks in PlatformCursor code. The changes to that are
on their way to upstream.

----

Bug: 1085700
Change-Id: I77b943fe8e54982b97c40a4f34bbbca66ab3f726
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2336597Reviewed-by: default avatarThomas Anderson <thomasanderson@chromium.org>
Commit-Queue: Maksim Sisov (GMT+3) <msisov@igalia.com>
Cr-Commit-Position: refs/heads/master@{#794876}
parent fdebc2f2
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
#include "ui/aura/window.h" #include "ui/aura/window.h"
#include "ui/aura/window_event_dispatcher.h" #include "ui/aura/window_event_dispatcher.h"
#include "ui/base/hit_test.h" #include "ui/base/hit_test.h"
#include "ui/base/ui_base_features.h"
#include "ui/base/x/x11_display_manager.h" #include "ui/base/x/x11_display_manager.h"
#include "ui/base/x/x11_util.h" #include "ui/base/x/x11_util.h"
#include "ui/display/display.h" #include "ui/display/display.h"
...@@ -70,6 +71,9 @@ class DesktopScreenX11Test : public views::ViewsTestBase, ...@@ -70,6 +71,9 @@ class DesktopScreenX11Test : public views::ViewsTestBase,
// Overridden from testing::Test: // Overridden from testing::Test:
void SetUp() override { void SetUp() override {
ViewsTestBase::SetUp(); ViewsTestBase::SetUp();
// TODO(msisov): rewrite desktop screen tests for ozone and non-ozone Linux.
if (features::IsUsingOzonePlatform())
GTEST_SKIP();
// Initialize the world to the single monitor case. // Initialize the world to the single monitor case.
std::vector<display::Display> displays; std::vector<display::Display> displays;
displays.emplace_back(kFirstDisplay, gfx::Rect(0, 0, 640, 480)); displays.emplace_back(kFirstDisplay, gfx::Rect(0, 0, 640, 480));
......
...@@ -487,6 +487,9 @@ class X11DragDropClientTest : public ViewsTestBase { ...@@ -487,6 +487,9 @@ class X11DragDropClientTest : public ViewsTestBase {
set_native_widget_type(NativeWidgetType::kDesktop); set_native_widget_type(NativeWidgetType::kDesktop);
ViewsTestBase::SetUp(); ViewsTestBase::SetUp();
// TODO(msisov): rewrite these tests for ozone and non-ozone Linux.
if (features::IsUsingOzonePlatform())
GTEST_SKIP();
// Create widget to initiate the drags. // Create widget to initiate the drags.
widget_ = std::make_unique<Widget>(); widget_ = std::make_unique<Widget>();
......
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