| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_SIGNIN_FAKE_SIGNIN_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_SIGNIN_FAKE_SIGNIN_MANAGER_H_ |
| 6 #define CHROME_BROWSER_SIGNIN_FAKE_SIGNIN_MANAGER_H_ | 6 #define CHROME_BROWSER_SIGNIN_FAKE_SIGNIN_MANAGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 30 matching lines...) Expand all Loading... |
| 41 virtual ~FakeSigninManager(); | 41 virtual ~FakeSigninManager(); |
| 42 | 42 |
| 43 void set_auth_in_progress(const std::string& username) { | 43 void set_auth_in_progress(const std::string& username) { |
| 44 possibly_invalid_username_ = username; | 44 possibly_invalid_username_ = username; |
| 45 } | 45 } |
| 46 | 46 |
| 47 void set_password(const std::string& password) { password_ = password; } | 47 void set_password(const std::string& password) { password_ = password; } |
| 48 | 48 |
| 49 void SignIn(const std::string& username, const std::string& password); | 49 void SignIn(const std::string& username, const std::string& password); |
| 50 | 50 |
| 51 void FailSignin(const GoogleServiceAuthError& error); |
| 52 |
| 51 virtual void SignOut() OVERRIDE; | 53 virtual void SignOut() OVERRIDE; |
| 52 | 54 |
| 53 virtual void StartSignInWithCredentials( | 55 virtual void StartSignInWithCredentials( |
| 54 const std::string& session_index, | 56 const std::string& session_index, |
| 55 const std::string& username, | 57 const std::string& username, |
| 56 const std::string& password, | 58 const std::string& password, |
| 57 const OAuthTokenFetchedCallback& oauth_fetched_callback) OVERRIDE; | 59 const OAuthTokenFetchedCallback& oauth_fetched_callback) OVERRIDE; |
| 58 | 60 |
| 59 virtual void CompletePendingSignin() OVERRIDE; | 61 virtual void CompletePendingSignin() OVERRIDE; |
| 60 }; | 62 }; |
| 61 | 63 |
| 62 #endif // !defined (OS_CHROMEOS) | 64 #endif // !defined (OS_CHROMEOS) |
| 63 | 65 |
| 64 #if defined(OS_CHROMEOS) | 66 #if defined(OS_CHROMEOS) |
| 65 typedef FakeSigninManagerBase FakeSigninManagerForTesting; | 67 typedef FakeSigninManagerBase FakeSigninManagerForTesting; |
| 66 #else | 68 #else |
| 67 typedef FakeSigninManager FakeSigninManagerForTesting; | 69 typedef FakeSigninManager FakeSigninManagerForTesting; |
| 68 #endif | 70 #endif |
| 69 | 71 |
| 70 #endif // CHROME_BROWSER_SIGNIN_FAKE_SIGNIN_MANAGER_H_ | 72 #endif // CHROME_BROWSER_SIGNIN_FAKE_SIGNIN_MANAGER_H_ |
| OLD | NEW |