Index: chrome/browser/chromeos/login/test_login_utils.cc |
diff --git a/chrome/browser/chromeos/login/test_login_utils.cc b/chrome/browser/chromeos/login/test_login_utils.cc |
index 4329370653a725348d036907ea107b7b9f2ee276..b673acac3bc01ce8bffb85b3f17ad1fdfb21816d 100644 |
--- a/chrome/browser/chromeos/login/test_login_utils.cc |
+++ b/chrome/browser/chromeos/login/test_login_utils.cc |
@@ -4,27 +4,26 @@ |
#include "chrome/browser/chromeos/login/test_login_utils.h" |
+#include "base/logging.h" |
#include "chrome/browser/chromeos/login/auth/mock_authenticator.h" |
#include "chrome/browser/chromeos/login/auth/user_context.h" |
namespace chromeos { |
-TestLoginUtils::TestLoginUtils(const std::string& expected_username, |
- const std::string& expected_password) |
- : expected_username_(expected_username), |
- expected_password_(expected_password) { |
+TestLoginUtils::TestLoginUtils(const UserContext& user_context) |
+ : expected_user_context_(user_context) { |
} |
TestLoginUtils::~TestLoginUtils() {} |
void TestLoginUtils::PrepareProfile( |
- const UserContext& credentials, |
+ const UserContext& user_context, |
const std::string& display_email, |
bool has_cookies, |
bool has_active_session, |
Delegate* delegate) { |
- DCHECK_EQ(expected_username_, credentials.GetUserID()); |
- DCHECK_EQ(expected_password_, credentials.GetPassword()); |
+ if (user_context != expected_user_context_) |
+ NOTREACHED(); |
// Profile hasn't been loaded. |
delegate->OnProfilePrepared(NULL); |
} |
@@ -34,8 +33,7 @@ void TestLoginUtils::DelegateDeleted(Delegate* delegate) { |
scoped_refptr<Authenticator> TestLoginUtils::CreateAuthenticator( |
LoginStatusConsumer* consumer) { |
- return new MockAuthenticator( |
- consumer, expected_username_, expected_password_); |
+ return new MockAuthenticator(consumer, expected_user_context_); |
} |
void TestLoginUtils::InitRlzDelayed(Profile* user_profile) { |