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

Unified Diff: chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm

Issue 1301583004: Revert of Delete dead signin code (SigninGlobalError) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_controller.mm ('k') | chrome/browser/ui/toolbar/wrench_menu_model.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm
diff --git a/chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm b/chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm
index a11e498b966391f55663de8bd5d1701009f01cd4..1e3f17fe9334727b7e65814ce954b9970f6a38de 100644
--- a/chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm
+++ b/chrome/browser/ui/cocoa/panels/panel_cocoa_unittest.mm
@@ -308,6 +308,7 @@
NSMenuItem* fullscreen_menu_item = CreateMenuItem(menu, IDC_FULLSCREEN);
NSMenuItem* presentation_menu_item =
CreateMenuItem(menu, IDC_PRESENTATION_MODE);
+ NSMenuItem* sync_menu_item = CreateMenuItem(menu, IDC_SHOW_SYNC_SETUP);
NSMenuItem* dev_tools_item = CreateMenuItem(menu, IDC_DEV_TOOLS);
NSMenuItem* dev_tools_console_item =
CreateMenuItem(menu, IDC_DEV_TOOLS_CONSOLE);
@@ -326,6 +327,7 @@
EXPECT_FALSE([find_next_menu_item isEnabled]);
EXPECT_FALSE([fullscreen_menu_item isEnabled]);
EXPECT_FALSE([presentation_menu_item isEnabled]);
+ EXPECT_FALSE([sync_menu_item isEnabled]);
// These are not enabled by Panel, so they are expected to be disabled for
// this unit_test. In real Chrome app, they are enabled by Chrome NSApp
// controller. PanelCocoaBrowsertest.MenuItems verifies that.
@@ -335,6 +337,11 @@
EXPECT_TRUE([dev_tools_item isEnabled]);
EXPECT_TRUE([dev_tools_console_item isEnabled]);
+
+ // Verify that commandDispatch on an invalid menu item does not crash.
+ [NSApp sendAction:[sync_menu_item action]
+ to:[sync_menu_item target]
+ from:sync_menu_item];
ClosePanelAndWait(panel);
}
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_controller.mm ('k') | chrome/browser/ui/toolbar/wrench_menu_model.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698