Chromium Code Reviews| Index: sync/internal_api/public/test/fake_sync_manager.h |
| diff --git a/sync/internal_api/public/test/fake_sync_manager.h b/sync/internal_api/public/test/fake_sync_manager.h |
| index b8e54711291363645be9ae6d7bd212e579aee841..2a8c36d1ef08560bec0d487682362d2521248b39 100644 |
| --- a/sync/internal_api/public/test/fake_sync_manager.h |
| +++ b/sync/internal_api/public/test/fake_sync_manager.h |
| @@ -20,24 +20,24 @@ namespace syncer { |
| class FakeSyncManager : public SyncManager { |
| public: |
| - explicit FakeSyncManager(); |
| - virtual ~FakeSyncManager(); |
| - |
| - // The set of types that have initial_sync_ended set to true. This value will |
| - // be used by InitialSyncEndedTypes() until the next configuration is |
| - // performed. |
| - void set_initial_sync_ended_types(ModelTypeSet types); |
| - |
| - // The set of types that have valid progress markers. This will be used by |
| - // GetTypesWithEmptyProgressMarkerToken() until the next configuration is |
| + // |initial_sync_ended_types|: The set of types that have |
|
msw
2012/08/03 23:30:46
nit: line breaks :)
akalin
2012/08/07 07:25:19
Done.
|
| + // initial_sync_ended set to true. This value will be used by |
| + // InitialSyncEndedTypes() until the next configuration is |
| // performed. |
| - void set_progress_marker_types(ModelTypeSet types); |
| - |
| - // The set of types that will fail configuration. Once ConfigureSyncer is |
| - // called, the |initial_sync_ended_types_| and |
| - // |progress_marker_types_| will be updated to include those types |
| - // that didn't fail. |
| - void set_configure_fail_types(ModelTypeSet types); |
| + // |
| + // |progress_marker_types|: The set of types that have valid |
| + // progress markers. This will be used by |
| + // GetTypesWithEmptyProgressMarkerToken() until the next |
| + // configuration is performed. |
| + // |
| + // |configure_fail_types|: The set of types that will fail |
| + // configuration. Once ConfigureSyncer is called, the |
| + // |initial_sync_ended_types_| and |progress_marker_types_| will be |
| + // updated to include those types that didn't fail. |
| + FakeSyncManager(ModelTypeSet initial_sync_ended_types, |
| + ModelTypeSet progress_marker_types, |
| + ModelTypeSet configure_fail_types); |
| + virtual ~FakeSyncManager(); |
| // Returns those types that have been cleaned (purged from the directory) |
| // since the last call to GetAndResetCleanedTypes(), or since startup if never |
| @@ -64,6 +64,10 @@ class FakeSyncManager : public SyncManager { |
| // Posts a method to disable notifications on the sync thread. |
| void DisableNotifications(NotificationsDisabledReason reason); |
| + // Block until the sync thread has finished processing any pending |
|
msw
2012/08/03 23:30:46
nit: line breaks :)
akalin
2012/08/07 07:25:19
Done.
|
| + // messages. |
| + void WaitForSyncThread(); |
| + |
| // SyncManager implementation. |
| // Note: we treat whatever message loop this is called from as the sync |
| // loop for purposes of callbacks. |
| @@ -95,8 +99,11 @@ class FakeSyncManager : public SyncManager { |
| virtual bool PurgePartiallySyncedTypes() OVERRIDE; |
| virtual void UpdateCredentials(const SyncCredentials& credentials) OVERRIDE; |
| virtual void UpdateEnabledTypes(const ModelTypeSet& types) OVERRIDE; |
| + virtual void SetInvalidationHandler( |
| + const std::string& handler_name, |
| + SyncNotifierObserver* handler) OVERRIDE; |
| virtual void UpdateRegisteredInvalidationIds( |
| - SyncNotifierObserver* handler, const ObjectIdSet& ids) OVERRIDE; |
| + const std::string& handler_name, const ObjectIdSet& ids) OVERRIDE; |
| virtual void StartSyncingNormally( |
| const ModelSafeRoutingInfo& routing_info) OVERRIDE; |
| virtual void SetEncryptionPassphrase(const std::string& passphrase, |