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

Side by Side Diff: chrome/browser/ui/cocoa/find_bar/find_bar_cocoa_controller_unittest.mm

Issue 2565813002: Create c/b/ui/cocoa/test and move test files to there (Closed)
Patch Set: Rebase Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/strings/string_util.h" 5 #include "base/strings/string_util.h"
6 #include "base/strings/sys_string_conversions.h" 6 #include "base/strings/sys_string_conversions.h"
7 #include "chrome/browser/ui/browser_window.h" 7 #include "chrome/browser/ui/browser_window.h"
8 #import "chrome/browser/ui/cocoa/cocoa_test_helper.h"
9 #import "chrome/browser/ui/cocoa/find_bar/find_bar_cocoa_controller.h" 8 #import "chrome/browser/ui/cocoa/find_bar/find_bar_cocoa_controller.h"
10 #import "chrome/browser/ui/cocoa/find_bar/find_bar_text_field.h" 9 #import "chrome/browser/ui/cocoa/find_bar/find_bar_text_field.h"
10 #import "chrome/browser/ui/cocoa/test/cocoa_test_helper.h"
11 #include "chrome/browser/ui/find_bar/find_notification_details.h" 11 #include "chrome/browser/ui/find_bar/find_notification_details.h"
12 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
13 #include "testing/platform_test.h" 13 #include "testing/platform_test.h"
14 #import "ui/base/cocoa/find_pasteboard.h" 14 #import "ui/base/cocoa/find_pasteboard.h"
15 15
16 // Expose private variables to make testing easier. 16 // Expose private variables to make testing easier.
17 @interface FindBarCocoaController(Testing) 17 @interface FindBarCocoaController(Testing)
18 - (FindBarTextField*)findTextField; 18 - (FindBarTextField*)findTextField;
19 @end 19 @end
20 20
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 TEST_F(FindBarCocoaControllerTest, SettingFindTextUpdatesFindPboard) { 127 TEST_F(FindBarCocoaControllerTest, SettingFindTextUpdatesFindPboard) {
128 NSString* const kFindText = 128 NSString* const kFindText =
129 @"It's not a bird, it's not a plane, it must be Dave who's on the train"; 129 @"It's not a bird, it's not a plane, it must be Dave who's on the train";
130 [controller_ setFindText:kFindText selectedRange:NSMakeRange(NSNotFound, 0)]; 130 [controller_ setFindText:kFindText selectedRange:NSMakeRange(NSNotFound, 0)];
131 EXPECT_EQ( 131 EXPECT_EQ(
132 NSOrderedSame, 132 NSOrderedSame,
133 [[[FindPasteboard sharedInstance] findText] compare:kFindText]); 133 [[[FindPasteboard sharedInstance] findText] compare:kFindText]);
134 } 134 }
135 135
136 } // namespace 136 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698