Chromium Code Reviews| Index: ash/wm/ash_native_cursor_manager_interactive_uitest.cc |
| diff --git a/ash/wm/ash_native_cursor_manager_interactive_uitest.cc b/ash/wm/ash_native_cursor_manager_interactive_uitest.cc |
| index cfdf03d1f89a41c632528941d3a98806fa5f1eac..cc4c85d74438eca886908db71c54a4f9f7c968bb 100644 |
| --- a/ash/wm/ash_native_cursor_manager_interactive_uitest.cc |
| +++ b/ash/wm/ash_native_cursor_manager_interactive_uitest.cc |
| @@ -1,6 +1,7 @@ |
| // Copyright 2013 The Chromium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| + |
| #include "ash/wm/ash_native_cursor_manager.h" |
| #include "ash/display/display_manager.h" |
| @@ -13,6 +14,10 @@ |
| #include "ui/base/test/ui_controls.h" |
| #include "ui/display/manager/managed_display_info.h" |
| +#if defined(OS_CHROMEOS) |
| +#include "ash/system/chromeos/screen_layout_observer.h" |
| +#endif |
| + |
| #if defined(USE_X11) |
| #include <X11/Xlib.h> |
| @@ -25,6 +30,21 @@ using AshNativeCursorManagerTest = test::AshInteractiveUITestBase; |
| namespace { |
| +#if defined(OS_CHROMEOS) |
| +class ScopedSuppressNotifications { |
| + public: |
| + ScopedSuppressNotifications() { |
| + ScreenLayoutObserver::SuppressNotificationsForTesting(true); |
| + } |
| + ~ScopedSuppressNotifications() { |
| + ScreenLayoutObserver::SuppressNotificationsForTesting(false); |
| + } |
| + |
| + private: |
| + DISALLOW_COPY_AND_ASSIGN(ScopedSuppressNotifications); |
| +}; |
| +#endif // defined(OS_CHROMEOS) |
| + |
| display::ManagedDisplayInfo CreateDisplayInfo(int64_t id, |
| const gfx::Rect& bounds, |
| float device_scale_factor) { |
| @@ -56,6 +76,12 @@ void MoveMouseSync(aura::Window* window, int x, int y) { |
| #endif |
| TEST_F(AshNativeCursorManagerTest, MAYBE_CursorChangeOnEnterNotify) { |
| +#if defined(OS_CHROMEOS) |
| + // Showing notifications causes crashes in Skia due to discardable memory |
| + // allocator problems. It's not clear why. |
| + ScopedSuppressNotifications suppress_notifications; |
|
oshima
2016/10/11 17:19:00
can you file a bug with a stack?
James Cook
2016/10/11 18:01:04
Added link to bug.
|
| +#endif |
| + |
| ::wm::CursorManager* cursor_manager = Shell::GetInstance()->cursor_manager(); |
| test::CursorManagerTestApi test_api(cursor_manager); |