OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 #import <Cocoa/Cocoa.h> | 5 #import <Cocoa/Cocoa.h> |
6 | 6 |
7 #include "base/scoped_nsautorelease_pool.h" | |
8 #import "base/scoped_nsobject.h" | 7 #import "base/scoped_nsobject.h" |
9 #import "chrome/browser/cocoa/tab_controller.h" | 8 #import "chrome/browser/cocoa/tab_controller.h" |
10 #import "chrome/browser/cocoa/tab_controller_target.h" | 9 #import "chrome/browser/cocoa/tab_controller_target.h" |
11 #include "chrome/browser/cocoa/cocoa_test_helper.h" | 10 #include "chrome/browser/cocoa/cocoa_test_helper.h" |
12 #include "testing/gtest/include/gtest/gtest.h" | 11 #include "testing/gtest/include/gtest/gtest.h" |
13 #include "testing/platform_test.h" | 12 #include "testing/platform_test.h" |
14 | 13 |
15 // Implements the target interface for the tab, which gets sent messages when | 14 // Implements the target interface for the tab, which gets sent messages when |
16 // the tab is clicked on by the user and when its close box is clicked. | 15 // the tab is clicked on by the user and when its close box is clicked. |
17 @interface TabControllerTestTarget : NSObject<TabControllerTarget> { | 16 @interface TabControllerTestTarget : NSObject<TabControllerTarget> { |
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 int cap = [controller iconCapacity]; | 258 int cap = [controller iconCapacity]; |
260 EXPECT_GT(cap, 0); | 259 EXPECT_GT(cap, 0); |
261 | 260 |
262 // Asking the view for its menu should yield a valid menu. | 261 // Asking the view for its menu should yield a valid menu. |
263 NSMenu* menu = [[controller view] menu]; | 262 NSMenu* menu = [[controller view] menu]; |
264 EXPECT_TRUE(menu); | 263 EXPECT_TRUE(menu); |
265 EXPECT_GT([menu numberOfItems], 0); | 264 EXPECT_GT([menu numberOfItems], 0); |
266 } | 265 } |
267 | 266 |
268 } // namespace | 267 } // namespace |
OLD | NEW |