Chromium Code Reviews| Index: components/sync/api/fake_model_type_service.h |
| diff --git a/components/sync/api/fake_model_type_service.h b/components/sync/api/fake_model_type_service.h |
| index 8924601e3331737843c78d6e51721b2a5614841b..9153d3418e50e95dfc6014245cf62a4a0a75913d 100644 |
| --- a/components/sync/api/fake_model_type_service.h |
| +++ b/components/sync/api/fake_model_type_service.h |
| @@ -112,6 +112,13 @@ class FakeModelTypeService : public ModelTypeService { |
| std::string GetClientTag(const EntityData& entity_data) override; |
| std::string GetStorageKey(const EntityData& entity_data) override; |
| void OnChangeProcessorSet() override; |
| + ConflictResolution ResolveConflict( |
| + const EntityData& local_data, |
| + const EntityData& remote_data) const override; |
| + |
| + // Store a resolution for the next call to ResolveConflict. Note that if this |
| + // is a USE_NEW resolution, the data will only exist for one resolve call. |
| + void SetConflictResolution(ConflictResolution resolution); |
|
skym
2016/09/26 18:16:04
This doesn't really handle scenarios where you hav
maxbogue
2016/09/27 16:26:12
Yeah, exactly. Also it sticks around for anything
|
| // Sets the error that the next fallible call to the service will generate. |
| void SetServiceError(syncer::SyncError::ErrorType error_type); |
| @@ -129,6 +136,9 @@ class FakeModelTypeService : public ModelTypeService { |
| // Applies |change_list| to the metadata store. |
| void ApplyMetadataChangeList(std::unique_ptr<MetadataChangeList> change_list); |
| + // The conflict resolution to use for calls to ResolveConflict. |
| + std::unique_ptr<ConflictResolution> conflict_resolution_; |
| + |
| // The error to produce on the next service call. |
| syncer::SyncError service_error_; |
| }; |