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

Unified Diff: chrome/browser/signin/signin_error_notifier_ash_unittest.cc

Issue 240453006: Fix sign-in error strings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Put error in button 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/signin/signin_error_notifier_ash_unittest.cc
diff --git a/chrome/browser/signin/signin_error_notifier_ash_unittest.cc b/chrome/browser/signin/signin_error_notifier_ash_unittest.cc
index c8e7b5e4536760078c91f97f2686aa01fb3de55d..23836807b198eb00e6acbd6c1ae0cb1e860ea7e7 100644
--- a/chrome/browser/signin/signin_error_notifier_ash_unittest.cc
+++ b/chrome/browser/signin/signin_error_notifier_ash_unittest.cc
@@ -38,6 +38,7 @@ namespace test {
namespace {
static const char kTestAccountId[] = "testuser@test.com";
+static const char kTestUsername[] = "testuser@test.com";
// Notification ID corresponding to kProfileSigninNotificationId +
// kTestAccountId.
@@ -130,8 +131,11 @@ TEST_F(SigninErrorNotifierTest, ErrorAuthStatusProvider) {
ASSERT_FALSE(notification_ui_manager_->FindById(kNotificationId));
{
FakeAuthStatusProvider error_provider(error_controller_);
- error_provider.SetAuthError(kTestAccountId, GoogleServiceAuthError(
- GoogleServiceAuthError::INVALID_GAIA_CREDENTIALS));
+ error_provider.SetAuthError(
+ kTestAccountId,
+ kTestUsername,
+ GoogleServiceAuthError(
+ GoogleServiceAuthError::INVALID_GAIA_CREDENTIALS));
ASSERT_TRUE(notification_ui_manager_->FindById(kNotificationId));
}
// error_provider is removed now that we've left that scope.
@@ -147,6 +151,7 @@ TEST_F(SigninErrorNotifierTest, AuthStatusProviderErrorTransition) {
FakeAuthStatusProvider provider1(error_controller_);
provider0.SetAuthError(
kTestAccountId,
+ kTestUsername,
GoogleServiceAuthError(
GoogleServiceAuthError::INVALID_GAIA_CREDENTIALS));
ASSERT_TRUE(notification_ui_manager_->FindById(kNotificationId));
@@ -158,10 +163,13 @@ TEST_F(SigninErrorNotifierTest, AuthStatusProviderErrorTransition) {
// Now set another auth error and clear the original.
provider1.SetAuthError(
kTestAccountId,
+ kTestUsername,
GoogleServiceAuthError(
GoogleServiceAuthError::UNEXPECTED_SERVICE_RESPONSE));
provider0.SetAuthError(
- kTestAccountId, GoogleServiceAuthError::AuthErrorNone());
+ kTestAccountId,
+ kTestUsername,
+ GoogleServiceAuthError::AuthErrorNone());
ASSERT_TRUE(notification_ui_manager_->FindById(kNotificationId));
@@ -172,7 +180,7 @@ TEST_F(SigninErrorNotifierTest, AuthStatusProviderErrorTransition) {
ASSERT_NE(new_message, message);
provider1.SetAuthError(
- kTestAccountId, GoogleServiceAuthError::AuthErrorNone());
+ kTestAccountId, kTestUsername, GoogleServiceAuthError::AuthErrorNone());
ASSERT_FALSE(notification_ui_manager_->FindById(kNotificationId));
}
}
@@ -205,6 +213,7 @@ TEST_F(SigninErrorNotifierTest, AuthStatusEnumerateAllErrors) {
for (size_t i = 0; i < ARRAYSIZE_UNSAFE(table); ++i) {
FakeAuthStatusProvider provider(error_controller_);
provider.SetAuthError(kTestAccountId,
+ kTestUsername,
GoogleServiceAuthError(table[i].error_state));
const Notification* notification = notification_ui_manager_->
FindById(kNotificationId);

Powered by Google App Engine
This is Rietveld 408576698