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

Side by Side Diff: chrome/browser/chromeos/login/login_browsertest.cc

Issue 378513005: [Athena] Extract Chrome OS authentication stack (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix includes in one more test Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ash/shell.h" 5 #include "ash/shell.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "chrome/browser/chrome_notification_types.h" 7 #include "chrome/browser/chrome_notification_types.h"
8 #include "chrome/browser/chromeos/login/login_wizard.h" 8 #include "chrome/browser/chromeos/login/login_wizard.h"
9 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h" 9 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h"
10 #include "chrome/browser/chromeos/login/users/user_manager.h"
11 #include "chrome/browser/chromeos/login/wizard_controller.h" 10 #include "chrome/browser/chromeos/login/wizard_controller.h"
12 #include "chrome/browser/profiles/profile_manager.h" 11 #include "chrome/browser/profiles/profile_manager.h"
13 #include "chrome/browser/profiles/profiles_state.h" 12 #include "chrome/browser/profiles/profiles_state.h"
14 #include "chrome/browser/ui/browser.h" 13 #include "chrome/browser/ui/browser.h"
15 #include "chrome/common/chrome_constants.h" 14 #include "chrome/common/chrome_constants.h"
16 #include "chrome/common/chrome_switches.h" 15 #include "chrome/common/chrome_switches.h"
17 #include "chrome/test/base/in_process_browser_test.h" 16 #include "chrome/test/base/in_process_browser_test.h"
18 #include "chrome/test/base/interactive_test_utils.h" 17 #include "chrome/test/base/interactive_test_utils.h"
19 #include "chrome/test/base/tracing.h" 18 #include "chrome/test/base/tracing.h"
20 #include "chrome/test/base/ui_test_utils.h" 19 #include "chrome/test/base/ui_test_utils.h"
21 #include "chromeos/chromeos_switches.h" 20 #include "chromeos/chromeos_switches.h"
21 #include "chromeos/login/user_names.h"
22 #include "content/public/test/test_utils.h" 22 #include "content/public/test/test_utils.h"
23 #include "extensions/browser/extension_system.h" 23 #include "extensions/browser/extension_system.h"
24 #include "testing/gmock/include/gmock/gmock.h" 24 #include "testing/gmock/include/gmock/gmock.h"
25 #include "testing/gtest/include/gtest/gtest.h" 25 #include "testing/gtest/include/gtest/gtest.h"
26 26
27 using ::testing::_; 27 using ::testing::_;
28 using ::testing::AnyNumber; 28 using ::testing::AnyNumber;
29 using ::testing::Return; 29 using ::testing::Return;
30 30
31 namespace { 31 namespace {
32 32
33 class LoginUserTest : public InProcessBrowserTest { 33 class LoginUserTest : public InProcessBrowserTest {
34 protected: 34 protected:
35 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { 35 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
36 command_line->AppendSwitchASCII( 36 command_line->AppendSwitchASCII(
37 chromeos::switches::kLoginUser, "TestUser@gmail.com"); 37 chromeos::switches::kLoginUser, "TestUser@gmail.com");
38 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, 38 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile,
39 "hash"); 39 "hash");
40 } 40 }
41 }; 41 };
42 42
43 class LoginGuestTest : public InProcessBrowserTest { 43 class LoginGuestTest : public InProcessBrowserTest {
44 protected: 44 protected:
45 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { 45 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
46 command_line->AppendSwitch(chromeos::switches::kGuestSession); 46 command_line->AppendSwitch(chromeos::switches::kGuestSession);
47 command_line->AppendSwitch(::switches::kIncognito); 47 command_line->AppendSwitch(::switches::kIncognito);
48 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, 48 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile,
49 "hash"); 49 "hash");
50 command_line->AppendSwitchASCII(chromeos::switches::kLoginUser, 50 command_line->AppendSwitchASCII(chromeos::switches::kLoginUser,
51 chromeos::UserManager::kGuestUserName); 51 chromeos::login::kGuestUserName);
52 } 52 }
53 }; 53 };
54 54
55 class LoginCursorTest : public InProcessBrowserTest { 55 class LoginCursorTest : public InProcessBrowserTest {
56 protected: 56 protected:
57 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { 57 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
58 command_line->AppendSwitch(chromeos::switches::kLoginManager); 58 command_line->AppendSwitch(chromeos::switches::kLoginManager);
59 } 59 }
60 }; 60 };
61 61
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 119
120 // Verifies that the webui for login comes up successfully. 120 // Verifies that the webui for login comes up successfully.
121 IN_PROC_BROWSER_TEST_F(LoginSigninTest, WebUIVisible) { 121 IN_PROC_BROWSER_TEST_F(LoginSigninTest, WebUIVisible) {
122 base::TimeDelta no_timeout; 122 base::TimeDelta no_timeout;
123 EXPECT_TRUE(tracing::WaitForWatchEvent(no_timeout)); 123 EXPECT_TRUE(tracing::WaitForWatchEvent(no_timeout));
124 std::string json_events; 124 std::string json_events;
125 ASSERT_TRUE(tracing::EndTracing(&json_events)); 125 ASSERT_TRUE(tracing::EndTracing(&json_events));
126 } 126 }
127 127
128 } // namespace 128 } // namespace
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/lock/screen_locker_browsertest.cc ('k') | chrome/browser/chromeos/login/login_manager_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698