OLD | NEW |
---|---|
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/scoped_nsobject.h" | 5 #include "base/scoped_nsobject.h" |
6 #include "chrome/app/chrome_command_ids.h" | 6 #include "chrome/app/chrome_command_ids.h" |
7 #include "chrome/browser/ui/cocoa/browser_test_helper.h" | 7 #include "chrome/browser/ui/cocoa/browser_test_helper.h" |
8 #import "chrome/browser/ui/cocoa/cocoa_test_helper.h" | 8 #import "chrome/browser/ui/cocoa/cocoa_test_helper.h" |
9 #import "chrome/browser/ui/cocoa/toolbar_controller.h" | 9 #import "chrome/browser/ui/cocoa/toolbar_controller.h" |
10 #import "chrome/browser/ui/cocoa/wrench_menu_controller.h" | 10 #import "chrome/browser/ui/cocoa/wrench_menu/wrench_menu_controller.h" |
Avi (use Gerrit)
2011/01/14 16:52:01
Alphabetize.
| |
11 #import "chrome/browser/ui/cocoa/view_resizer_pong.h" | 11 #import "chrome/browser/ui/cocoa/view_resizer_pong.h" |
12 #include "chrome/browser/ui/toolbar/wrench_menu_model.h" | 12 #include "chrome/browser/ui/toolbar/wrench_menu_model.h" |
13 #include "testing/gmock/include/gmock/gmock.h" | 13 #include "testing/gmock/include/gmock/gmock.h" |
14 #include "testing/gtest/include/gtest/gtest.h" | 14 #include "testing/gtest/include/gtest/gtest.h" |
15 #include "testing/platform_test.h" | 15 #include "testing/platform_test.h" |
16 | 16 |
17 // Override to avoid dealing with run loops in the testing environment. | 17 // Override to avoid dealing with run loops in the testing environment. |
18 @implementation WrenchMenuController (UnitTesting) | 18 @implementation WrenchMenuController (UnitTesting) |
19 - (void)dispatchCommandInternal:(NSInteger)tag { | 19 - (void)dispatchCommandInternal:(NSInteger)tag { |
20 [self wrenchMenuModel]->ExecuteCommand(tag); | 20 [self wrenchMenuModel]->ExecuteCommand(tag); |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
75 [button setTag:IDC_ZOOM_PLUS]; | 75 [button setTag:IDC_ZOOM_PLUS]; |
76 | 76 |
77 // Set fake model to test dispatching. | 77 // Set fake model to test dispatching. |
78 EXPECT_CALL(fake_model_, ExecuteCommand(IDC_ZOOM_PLUS)); | 78 EXPECT_CALL(fake_model_, ExecuteCommand(IDC_ZOOM_PLUS)); |
79 [controller() setModel:&fake_model_]; | 79 [controller() setModel:&fake_model_]; |
80 | 80 |
81 [controller() dispatchWrenchMenuCommand:button.get()]; | 81 [controller() dispatchWrenchMenuCommand:button.get()]; |
82 } | 82 } |
83 | 83 |
84 } // namespace | 84 } // namespace |
OLD | NEW |