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

Side by Side Diff: extensions/shell/browser/shell_browsertest.cc

Issue 2281053004: Remove extensions_tests.gyp[i] (Closed)
Patch Set: chromeos Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « extensions/shell/BUILD.gn ('k') | extensions/utility/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/logging.h" 5 #include "base/logging.h"
6 #include "content/public/browser/notification_service.h" 6 #include "content/public/browser/notification_service.h"
7 #include "content/public/browser/web_contents.h" 7 #include "content/public/browser/web_contents.h"
8 #include "content/public/test/test_utils.h" 8 #include "content/public/test/test_utils.h"
9 #include "extensions/browser/app_window/app_window.h" 9 #include "extensions/browser/app_window/app_window.h"
10 #include "extensions/browser/app_window/app_window_registry.h" 10 #include "extensions/browser/app_window/app_window_registry.h"
11 #include "extensions/browser/notification_types.h" 11 #include "extensions/browser/notification_types.h"
12 #include "extensions/shell/test/shell_apitest.h" 12 #include "extensions/shell/test/shell_apitest.h"
13 13
14 #if defined(USE_AURA) 14 #if defined(USE_AURA)
15 #include "ui/aura/window.h" 15 #include "ui/aura/window.h" // nogncheck
16 #endif 16 #endif
17 17
18 namespace extensions { 18 namespace extensions {
19 19
20 // Test that we can open an app window and wait for it to load. 20 // Test that we can open an app window and wait for it to load.
21 IN_PROC_BROWSER_TEST_F(ShellApiTest, Basic) { 21 IN_PROC_BROWSER_TEST_F(ShellApiTest, Basic) {
22 ASSERT_TRUE(RunAppTest("platform_app")) << message_; 22 ASSERT_TRUE(RunAppTest("platform_app")) << message_;
23 23
24 // A window was created. 24 // A window was created.
25 AppWindow* app_window = 25 AppWindow* app_window =
26 AppWindowRegistry::Get(browser_context())->app_windows().front(); 26 AppWindowRegistry::Get(browser_context())->app_windows().front();
27 ASSERT_TRUE(app_window); 27 ASSERT_TRUE(app_window);
28 28
29 // TOOD(yoz): Test for focus on Cocoa. 29 // TOOD(yoz): Test for focus on Cocoa.
30 // app_window->GetBaseWindow()->IsActive() is possible, although on Mac, 30 // app_window->GetBaseWindow()->IsActive() is possible, although on Mac,
31 // focus changes are asynchronous, so interactive_ui_tests are required. 31 // focus changes are asynchronous, so interactive_ui_tests are required.
32 #if defined(USE_AURA) 32 #if defined(USE_AURA)
33 // The web contents have focus. 33 // The web contents have focus.
34 EXPECT_TRUE(app_window->web_contents()->GetContentNativeView()->HasFocus()); 34 EXPECT_TRUE(app_window->web_contents()->GetContentNativeView()->HasFocus());
35 #endif 35 #endif
36 } 36 }
37 37
38 } // namespace extensions 38 } // namespace extensions
OLDNEW
« no previous file with comments | « extensions/shell/BUILD.gn ('k') | extensions/utility/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698