| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_SYNC_GLUE_SHARED_CHANGE_PROCESSOR_MOCK_H_ | |
| 6 #define CHROME_BROWSER_SYNC_GLUE_SHARED_CHANGE_PROCESSOR_MOCK_H_ | |
| 7 | |
| 8 #include "chrome/browser/sync/glue/shared_change_processor.h" | |
| 9 #include "sync/api/sync_change.h" | |
| 10 #include "sync/api/sync_data.h" | |
| 11 #include "sync/internal_api/public/util/unrecoverable_error_handler.h" | |
| 12 #include "testing/gmock/include/gmock/gmock.h" | |
| 13 | |
| 14 namespace browser_sync { | |
| 15 | |
| 16 class SharedChangeProcessorMock : public SharedChangeProcessor { | |
| 17 public: | |
| 18 SharedChangeProcessorMock(); | |
| 19 | |
| 20 MOCK_METHOD5(Connect, base::WeakPtr<syncer::SyncableService>( | |
| 21 ProfileSyncComponentsFactory*, | |
| 22 ProfileSyncService*, | |
| 23 DataTypeErrorHandler*, | |
| 24 syncer::ModelType, | |
| 25 const base::WeakPtr<syncer::SyncMergeResult>&)); | |
| 26 MOCK_METHOD0(Disconnect, bool()); | |
| 27 MOCK_METHOD2(ProcessSyncChanges, | |
| 28 syncer::SyncError(const tracked_objects::Location&, | |
| 29 const syncer::SyncChangeList&)); | |
| 30 MOCK_CONST_METHOD2(GetAllSyncDataReturnError, | |
| 31 syncer::SyncError(syncer::ModelType, | |
| 32 syncer::SyncDataList*)); | |
| 33 MOCK_METHOD0(GetSyncCount, int()); | |
| 34 MOCK_METHOD1(SyncModelHasUserCreatedNodes, | |
| 35 bool(bool*)); | |
| 36 MOCK_METHOD0(CryptoReadyIfNecessary, bool()); | |
| 37 MOCK_CONST_METHOD1(GetDataTypeContext, bool(std::string*)); | |
| 38 MOCK_METHOD1(ActivateDataType, | |
| 39 void(syncer::ModelSafeGroup)); | |
| 40 | |
| 41 protected: | |
| 42 virtual ~SharedChangeProcessorMock(); | |
| 43 MOCK_METHOD2(OnUnrecoverableError, void(const tracked_objects::Location&, | |
| 44 const std::string&)); | |
| 45 | |
| 46 private: | |
| 47 DISALLOW_COPY_AND_ASSIGN(SharedChangeProcessorMock); | |
| 48 }; | |
| 49 | |
| 50 } // namespace browser_sync | |
| 51 | |
| 52 #endif // CHROME_BROWSER_SYNC_GLUE_SHARED_CHANGE_PROCESSOR_MOCK_H_ | |
| OLD | NEW |