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

Side by Side Diff: chrome/browser/ui/cocoa/applescript/window_applescript_test.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 #import <Cocoa/Cocoa.h> 5 #import <Cocoa/Cocoa.h>
6 6
7 #import "base/mac/foundation_util.h" 7 #import "base/mac/foundation_util.h"
8 #include "base/mac/mac_util.h" 8 #include "base/mac/mac_util.h"
9 #import "base/mac/scoped_nsobject.h" 9 #import "base/mac/scoped_nsobject.h"
10 #include "base/strings/sys_string_conversions.h" 10 #include "base/strings/sys_string_conversions.h"
11 #import "chrome/browser/app_controller_mac.h" 11 #import "chrome/browser/app_controller_mac.h"
12 #import "chrome/browser/chrome_browser_application_mac.h" 12 #import "chrome/browser/chrome_browser_application_mac.h"
13 #include "chrome/browser/profiles/profile.h" 13 #include "chrome/browser/profiles/profile.h"
14 #import "chrome/browser/ui/cocoa/applescript/constants_applescript.h" 14 #import "chrome/browser/ui/cocoa/applescript/constants_applescript.h"
15 #import "chrome/browser/ui/cocoa/applescript/error_applescript.h" 15 #import "chrome/browser/ui/cocoa/applescript/error_applescript.h"
16 #import "chrome/browser/ui/cocoa/applescript/tab_applescript.h" 16 #import "chrome/browser/ui/cocoa/applescript/tab_applescript.h"
17 #import "chrome/browser/ui/cocoa/applescript/window_applescript.h" 17 #import "chrome/browser/ui/cocoa/applescript/window_applescript.h"
18 #include "chrome/browser/ui/cocoa/run_loop_testing.h" 18 #include "chrome/browser/ui/cocoa/test/run_loop_testing.h"
19 #include "chrome/test/base/in_process_browser_test.h" 19 #include "chrome/test/base/in_process_browser_test.h"
20 #include "testing/gtest/include/gtest/gtest.h" 20 #include "testing/gtest/include/gtest/gtest.h"
21 #import "testing/gtest_mac.h" 21 #import "testing/gtest_mac.h"
22 #include "url/gurl.h" 22 #include "url/gurl.h"
23 23
24 typedef InProcessBrowserTest WindowAppleScriptTest; 24 typedef InProcessBrowserTest WindowAppleScriptTest;
25 25
26 // Create a window in default/normal mode. 26 // Create a window in default/normal mode.
27 IN_PROC_BROWSER_TEST_F(WindowAppleScriptTest, DefaultCreation) { 27 IN_PROC_BROWSER_TEST_F(WindowAppleScriptTest, DefaultCreation) {
28 base::scoped_nsobject<WindowAppleScript> aWindow( 28 base::scoped_nsobject<WindowAppleScript> aWindow(
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 IN_PROC_BROWSER_TEST_F(WindowAppleScriptTest, WindowOrder) { 177 IN_PROC_BROWSER_TEST_F(WindowAppleScriptTest, WindowOrder) {
178 base::scoped_nsobject<WindowAppleScript> window2( 178 base::scoped_nsobject<WindowAppleScript> window2(
179 [[WindowAppleScript alloc] initWithBrowser:browser()]); 179 [[WindowAppleScript alloc] initWithBrowser:browser()]);
180 base::scoped_nsobject<WindowAppleScript> window1( 180 base::scoped_nsobject<WindowAppleScript> window1(
181 [[WindowAppleScript alloc] init]); 181 [[WindowAppleScript alloc] init]);
182 chrome::testing::NSRunLoopRunAllPending(); 182 chrome::testing::NSRunLoopRunAllPending();
183 EXPECT_EQ([window1.get() windowComparator:window2.get()], NSOrderedAscending); 183 EXPECT_EQ([window1.get() windowComparator:window2.get()], NSOrderedAscending);
184 EXPECT_EQ([window2.get() windowComparator:window1.get()], 184 EXPECT_EQ([window2.get() windowComparator:window1.get()],
185 NSOrderedDescending); 185 NSOrderedDescending);
186 } 186 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698