Chromium Code Reviews| Index: chrome/browser/sync/profile_sync_service_unittest.cc |
| diff --git a/chrome/browser/sync/profile_sync_service_unittest.cc b/chrome/browser/sync/profile_sync_service_unittest.cc |
| index 74040bdc951dce5c2ad8887bfae8a7915de8b6ef..a125be1475c4eb1209316b06eb39d0bf5263259b 100644 |
| --- a/chrome/browser/sync/profile_sync_service_unittest.cc |
| +++ b/chrome/browser/sync/profile_sync_service_unittest.cc |
| @@ -421,6 +421,18 @@ TEST_F(ProfileSyncServiceTest, FailToOpenDatabase) { |
| EXPECT_FALSE(harness_.service->sync_initialized()); |
| } |
| +// This setup will allow the database to exist, but leave it empty. The attempt |
| +// to download control types will silently fail (no downloads have any effect in |
| +// these tests). The sync_backend_host will notice this and inform the profile |
| +// sync service of the failure to initialize the backed. |
| +TEST_F(ProfileSyncServiceTest, FailToDownloadControlTypes) { |
| + harness_.StartSyncServiceAndSetInitialSyncEnded(false, true, true, true, |
|
Nicolas Zea
2012/12/11 19:35:00
I'd prefer having this test in SBH's unit tests, a
|
| + syncer::STORAGE_IN_MEMORY); |
| + |
| + // The backend is not ready. Ensure the PSS knows this. |
| + EXPECT_FALSE(harness_.service->sync_initialized()); |
| +} |
| + |
| // Register a handler with the ProfileSyncService, and disable and |
| // reenable sync. The handler should get notified of the state |
| // changes. |