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

Side by Side Diff: chrome/browser/chromeos/login/auth/test_attempt_state.cc

Issue 290483003: Tame the proliferation of UserContext constructors (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased. Created 6 years, 7 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 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 "chrome/browser/chromeos/login/auth/test_attempt_state.h" 5 #include "chrome/browser/chromeos/login/auth/test_attempt_state.h"
6 6
7 #include <string> 7 #include "chrome/browser/chromeos/login/users/user.h"
8
9 #include "google_apis/gaia/gaia_auth_consumer.h" 8 #include "google_apis/gaia/gaia_auth_consumer.h"
10 9
11 namespace chromeos { 10 namespace chromeos {
12 11
13 TestAttemptState::TestAttemptState(const UserContext& credentials, 12 TestAttemptState::TestAttemptState(const UserContext& credentials,
14 const std::string& login_token,
15 const std::string& login_captcha,
16 const User::UserType user_type,
17 const bool user_is_new) 13 const bool user_is_new)
18 : AuthAttemptState(credentials, 14 : AuthAttemptState(credentials,
19 login_token, 15 User::USER_TYPE_REGULAR,
20 login_captcha, 16 false, // unlock
21 user_type, 17 false, // online_complete
22 user_is_new) { 18 user_is_new) {
23 } 19 }
24 20
25 TestAttemptState::~TestAttemptState() {} 21 TestAttemptState::~TestAttemptState() {}
26 22
27 void TestAttemptState::PresetOnlineLoginStatus( 23 void TestAttemptState::PresetOnlineLoginStatus(
28 const LoginFailure& outcome) { 24 const LoginFailure& outcome) {
29 online_complete_ = true; 25 online_complete_ = true;
30 online_outcome_ = outcome; 26 online_outcome_ = outcome;
31 } 27 }
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 60
65 bool TestAttemptState::cryptohome_outcome() { 61 bool TestAttemptState::cryptohome_outcome() {
66 return cryptohome_outcome_; 62 return cryptohome_outcome_;
67 } 63 }
68 64
69 cryptohome::MountError TestAttemptState::cryptohome_code() { 65 cryptohome::MountError TestAttemptState::cryptohome_code() {
70 return cryptohome_code_; 66 return cryptohome_code_;
71 } 67 }
72 68
73 } // namespace chromeos 69 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/auth/test_attempt_state.h ('k') | chrome/browser/chromeos/login/existing_user_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698