| Index: trunk/src/sync/internal_api/test/sync_manager_for_profile_sync_test.cc
|
| ===================================================================
|
| --- trunk/src/sync/internal_api/test/sync_manager_for_profile_sync_test.cc (revision 238367)
|
| +++ trunk/src/sync/internal_api/test/sync_manager_for_profile_sync_test.cc (working copy)
|
| @@ -12,9 +12,11 @@
|
|
|
| SyncManagerForProfileSyncTest::SyncManagerForProfileSyncTest(
|
| std::string name,
|
| - base::Closure init_callback)
|
| + base::Closure init_callback,
|
| + bool set_initial_sync_ended)
|
| : SyncManagerImpl(name),
|
| - init_callback_(init_callback) {}
|
| + init_callback_(init_callback),
|
| + set_initial_sync_ended_(set_initial_sync_ended) {}
|
|
|
| SyncManagerForProfileSyncTest::~SyncManagerForProfileSyncTest() {}
|
|
|
| @@ -25,14 +27,18 @@
|
| if (!init_callback_.is_null())
|
| init_callback_.Run();
|
|
|
| - ModelTypeSet early_download_types;
|
| - early_download_types.PutAll(ControlTypes());
|
| - early_download_types.PutAll(PriorityUserTypes());
|
| - for (ModelTypeSet::Iterator it = early_download_types.First();
|
| - it.Good(); it.Inc()) {
|
| - if (!directory->InitialSyncEndedForType(it.Get())) {
|
| - syncer::TestUserShare::CreateRoot(it.Get(), user_share);
|
| + if (set_initial_sync_ended_) {
|
| + ModelTypeSet early_download_types;
|
| + early_download_types.PutAll(ControlTypes());
|
| + early_download_types.PutAll(PriorityUserTypes());
|
| + for (ModelTypeSet::Iterator it = early_download_types.First();
|
| + it.Good(); it.Inc()) {
|
| + if (!directory->InitialSyncEndedForType(it.Get())) {
|
| + syncer::TestUserShare::CreateRoot(it.Get(), user_share);
|
| + }
|
| }
|
| + } else {
|
| + VLOG(2) << "Skipping directory init";
|
| }
|
|
|
| SyncManagerImpl::NotifyInitializationSuccess();
|
|
|