Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2466)

Unified Diff: ash/drag_drop/drag_drop_tracker_unittest.cc

Issue 17445002: Updates the display message in the uber tray. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix test failures Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ash/drag_drop/drag_drop_tracker_unittest.cc
diff --git a/ash/drag_drop/drag_drop_tracker_unittest.cc b/ash/drag_drop/drag_drop_tracker_unittest.cc
index acb87a46a54b78db87ea7a0f09314a9a6d125823..081b04bc2bbb45ca2a27e8a6514bca9b0e8ad214 100644
--- a/ash/drag_drop/drag_drop_tracker_unittest.cc
+++ b/ash/drag_drop/drag_drop_tracker_unittest.cc
@@ -4,8 +4,10 @@
#include "ash/drag_drop/drag_drop_tracker.h"
+#include "ash/root_window_controller.h"
#include "ash/shell.h"
#include "ash/shell_window_ids.h"
+#include "ash/system/tray/system_tray.h"
#include "ash/test/ash_test_base.h"
#include "base/memory/scoped_ptr.h"
#include "ui/aura/root_window.h"
@@ -20,6 +22,14 @@ class DragDropTrackerTest : public test::AshTestBase {
virtual void SetUp() OVERRIDE {
AshTestBase::SetUp();
UpdateDisplay("200x200,200x200");
+ // close all notification for display change. Otherwise some event may
+ // happen on the notification bubble, which breaks the test expectation.
+ // TODO(mukai): remove this when the display change notification has moved
+ // to the message_center.
+ Shell::RootWindowControllerList root_controllers =
+ Shell::GetAllRootWindowControllers();
+ for (size_t i = 0; i < root_controllers.size(); ++i)
+ root_controllers[i]->GetSystemTray()->CloseNotificationBubbleForTest();
}
aura::Window* CreateTestWindow(const gfx::Rect& bounds) {

Powered by Google App Engine
This is Rietveld 408576698