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

Side by Side Diff: chromeos/login/auth/mock_authenticator.h

Issue 413473003: Revert of Refactoring : Move AuthAttempt and Authenticators to chromeos/login (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CHROMEOS_LOGIN_AUTH_MOCK_AUTHENTICATOR_H_
6 #define CHROMEOS_LOGIN_AUTH_MOCK_AUTHENTICATOR_H_
7
8 #include <string>
9
10 #include "chromeos/chromeos_export.h"
11 #include "chromeos/login/auth/authenticator.h"
12 #include "chromeos/login/auth/user_context.h"
13 #include "testing/gtest/include/gtest/gtest.h"
14
15 class Profile;
16
17 namespace chromeos {
18
19 class AuthStatusConsumer;
20
21 class CHROMEOS_EXPORT MockAuthenticator : public Authenticator {
22 public:
23 MockAuthenticator(AuthStatusConsumer* consumer,
24 const UserContext& expected_user_context);
25
26 // Authenticator:
27 virtual void CompleteLogin(Profile* profile,
28 const UserContext& user_context) OVERRIDE;
29 virtual void AuthenticateToLogin(Profile* profile,
30 const UserContext& user_context) OVERRIDE;
31 virtual void AuthenticateToUnlock(const UserContext& user_context) OVERRIDE;
32 virtual void LoginAsSupervisedUser(const UserContext& user_context) OVERRIDE;
33 virtual void LoginRetailMode() OVERRIDE;
34 virtual void LoginOffTheRecord() OVERRIDE;
35 virtual void LoginAsPublicAccount(const std::string& username) OVERRIDE;
36 virtual void LoginAsKioskAccount(const std::string& app_user_id,
37 bool use_guest_mount) OVERRIDE;
38 virtual void OnRetailModeAuthSuccess() OVERRIDE;
39 virtual void OnAuthSuccess() OVERRIDE;
40 virtual void OnAuthFailure(const AuthFailure& failure) OVERRIDE;
41 virtual void RecoverEncryptedData(const std::string& old_password) OVERRIDE;
42 virtual void ResyncEncryptedData() OVERRIDE;
43
44 virtual void SetExpectedCredentials(const UserContext& user_context);
45
46 protected:
47 virtual ~MockAuthenticator();
48
49 private:
50 UserContext expected_user_context_;
51
52 DISALLOW_COPY_AND_ASSIGN(MockAuthenticator);
53 };
54
55 } // namespace chromeos
56
57 #endif // CHROMEOS_LOGIN_AUTH_MOCK_AUTHENTICATOR_H_
OLDNEW
« no previous file with comments | « chromeos/login/auth/mock_auth_attempt_state_resolver.cc ('k') | chromeos/login/auth/mock_authenticator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698