| 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 #include <set> | 5 #include <set> |
| 6 #include "base/basictypes.h" | 6 #include "base/basictypes.h" |
| 7 #include "base/stringprintf.h" | 7 #include "base/stringprintf.h" |
| 8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
| 9 #include "chrome/browser/profiles/profile.h" | 9 #include "chrome/browser/profiles/profile.h" |
| 10 #include "chrome/browser/signin/signin_manager.h" | 10 #include "chrome/browser/signin/signin_manager.h" |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 EXPECT_CALL(service, HasUnrecoverableError()) | 250 EXPECT_CALL(service, HasUnrecoverableError()) |
| 251 .WillOnce(Return(false)); | 251 .WillOnce(Return(false)); |
| 252 EXPECT_CALL(signin, AuthInProgress()).WillRepeatedly(Return(false)); | 252 EXPECT_CALL(signin, AuthInProgress()).WillRepeatedly(Return(false)); |
| 253 EXPECT_CALL(service, GetAuthError()) | 253 EXPECT_CALL(service, GetAuthError()) |
| 254 .WillOnce(ReturnRef(**auth_error)); | 254 .WillOnce(ReturnRef(**auth_error)); |
| 255 return; | 255 return; |
| 256 } | 256 } |
| 257 case STATUS_CASE_PROTOCOL_ERROR: { | 257 case STATUS_CASE_PROTOCOL_ERROR: { |
| 258 EXPECT_CALL(service, HasSyncSetupCompleted()) | 258 EXPECT_CALL(service, HasSyncSetupCompleted()) |
| 259 .WillOnce(Return(true)); | 259 .WillOnce(Return(true)); |
| 260 csync::SyncProtocolError protocolError; | 260 syncer::SyncProtocolError protocolError; |
| 261 protocolError.action = csync::STOP_AND_RESTART_SYNC; | 261 protocolError.action = syncer::STOP_AND_RESTART_SYNC; |
| 262 browser_sync::SyncBackendHost::Status status; | 262 browser_sync::SyncBackendHost::Status status; |
| 263 status.sync_protocol_error = protocolError; | 263 status.sync_protocol_error = protocolError; |
| 264 EXPECT_CALL(service, QueryDetailedSyncStatus()) | 264 EXPECT_CALL(service, QueryDetailedSyncStatus()) |
| 265 .WillOnce(Return(status)); | 265 .WillOnce(Return(status)); |
| 266 *auth_error = new GoogleServiceAuthError(GoogleServiceAuthError::NONE); | 266 *auth_error = new GoogleServiceAuthError(GoogleServiceAuthError::NONE); |
| 267 EXPECT_CALL(service, GetAuthError()) | 267 EXPECT_CALL(service, GetAuthError()) |
| 268 .WillOnce(ReturnRef(**auth_error)); | 268 .WillOnce(ReturnRef(**auth_error)); |
| 269 EXPECT_CALL(signin, AuthInProgress()).WillRepeatedly(Return(false)); | 269 EXPECT_CALL(signin, AuthInProgress()).WillRepeatedly(Return(false)); |
| 270 EXPECT_CALL(service, HasUnrecoverableError()) | 270 EXPECT_CALL(service, HasUnrecoverableError()) |
| 271 .WillOnce(Return(false)); | 271 .WillOnce(Return(false)); |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 // Ensures a search for string 'href' (found in links, not a string to be | 361 // Ensures a search for string 'href' (found in links, not a string to be |
| 362 // found in an English language message) fails when links are excluded from | 362 // found in an English language message) fails when links are excluded from |
| 363 // the status label. | 363 // the status label. |
| 364 EXPECT_EQ(status_label.find(string16(ASCIIToUTF16("href"))), | 364 EXPECT_EQ(status_label.find(string16(ASCIIToUTF16("href"))), |
| 365 string16::npos); | 365 string16::npos); |
| 366 if (auth_error) { | 366 if (auth_error) { |
| 367 delete auth_error; | 367 delete auth_error; |
| 368 } | 368 } |
| 369 } | 369 } |
| 370 } | 370 } |
| OLD | NEW |