| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ | 5 #ifndef COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ |
| 6 #define COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ | 6 #define COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 MOCK_METHOD2(OnUserChoseDatatypes, | 43 MOCK_METHOD2(OnUserChoseDatatypes, |
| 44 void(bool sync_everything, syncer::ModelTypeSet chosen_types)); | 44 void(bool sync_everything, syncer::ModelTypeSet chosen_types)); |
| 45 | 45 |
| 46 MOCK_METHOD2(OnUnrecoverableError, | 46 MOCK_METHOD2(OnUnrecoverableError, |
| 47 void(const tracked_objects::Location& location, | 47 void(const tracked_objects::Location& location, |
| 48 const std::string& message)); | 48 const std::string& message)); |
| 49 MOCK_CONST_METHOD0(GetUserShare, syncer::UserShare*()); | 49 MOCK_CONST_METHOD0(GetUserShare, syncer::UserShare*()); |
| 50 MOCK_METHOD0(RequestStart, void()); | 50 MOCK_METHOD0(RequestStart, void()); |
| 51 MOCK_METHOD1(RequestStop, void(ProfileSyncService::SyncStopDataFate)); | 51 MOCK_METHOD1(RequestStop, void(ProfileSyncService::SyncStopDataFate)); |
| 52 | 52 |
| 53 MOCK_METHOD1(AddObserver, void(syncer::SyncServiceObserver*)); | 53 MOCK_METHOD1(AddObserver, void(sync_driver::SyncServiceObserver*)); |
| 54 MOCK_METHOD1(RemoveObserver, void(syncer::SyncServiceObserver*)); | 54 MOCK_METHOD1(RemoveObserver, void(sync_driver::SyncServiceObserver*)); |
| 55 MOCK_METHOD0(GetJsController, base::WeakPtr<syncer::JsController>()); | 55 MOCK_METHOD0(GetJsController, base::WeakPtr<syncer::JsController>()); |
| 56 MOCK_CONST_METHOD0(IsFirstSetupComplete, bool()); | 56 MOCK_CONST_METHOD0(IsFirstSetupComplete, bool()); |
| 57 | 57 |
| 58 MOCK_CONST_METHOD0(IsEncryptEverythingAllowed, bool()); | 58 MOCK_CONST_METHOD0(IsEncryptEverythingAllowed, bool()); |
| 59 MOCK_CONST_METHOD0(IsEncryptEverythingEnabled, bool()); | 59 MOCK_CONST_METHOD0(IsEncryptEverythingEnabled, bool()); |
| 60 MOCK_METHOD0(EnableEncryptEverything, void()); | 60 MOCK_METHOD0(EnableEncryptEverything, void()); |
| 61 | 61 |
| 62 MOCK_METHOD1(ChangePreferredDataTypes, | 62 MOCK_METHOD1(ChangePreferredDataTypes, |
| 63 void(syncer::ModelTypeSet preferred_types)); | 63 void(syncer::ModelTypeSet preferred_types)); |
| 64 MOCK_CONST_METHOD0(GetActiveDataTypes, syncer::ModelTypeSet()); | 64 MOCK_CONST_METHOD0(GetActiveDataTypes, syncer::ModelTypeSet()); |
| 65 MOCK_CONST_METHOD0(GetPreferredDataTypes, syncer::ModelTypeSet()); | 65 MOCK_CONST_METHOD0(GetPreferredDataTypes, syncer::ModelTypeSet()); |
| 66 MOCK_CONST_METHOD0(GetRegisteredDataTypes, syncer::ModelTypeSet()); | 66 MOCK_CONST_METHOD0(GetRegisteredDataTypes, syncer::ModelTypeSet()); |
| 67 MOCK_CONST_METHOD0(GetLastCycleSnapshot, syncer::SyncCycleSnapshot()); | 67 MOCK_CONST_METHOD0(GetLastCycleSnapshot, syncer::SyncCycleSnapshot()); |
| 68 | 68 |
| 69 MOCK_METHOD1(QueryDetailedSyncStatus, | 69 MOCK_METHOD1(QueryDetailedSyncStatus, bool(SyncBackendHost::Status* result)); |
| 70 bool(syncer::SyncBackendHost::Status* result)); | |
| 71 MOCK_CONST_METHOD0(GetAuthError, const GoogleServiceAuthError&()); | 70 MOCK_CONST_METHOD0(GetAuthError, const GoogleServiceAuthError&()); |
| 72 MOCK_CONST_METHOD0(IsFirstSetupInProgress, bool()); | 71 MOCK_CONST_METHOD0(IsFirstSetupInProgress, bool()); |
| 73 MOCK_CONST_METHOD0(GetLastSyncedTimeString, base::string16()); | 72 MOCK_CONST_METHOD0(GetLastSyncedTimeString, base::string16()); |
| 74 MOCK_CONST_METHOD0(HasUnrecoverableError, bool()); | 73 MOCK_CONST_METHOD0(HasUnrecoverableError, bool()); |
| 75 MOCK_CONST_METHOD0(IsSyncActive, bool()); | 74 MOCK_CONST_METHOD0(IsSyncActive, bool()); |
| 76 MOCK_CONST_METHOD0(IsBackendInitialized, bool()); | 75 MOCK_CONST_METHOD0(IsBackendInitialized, bool()); |
| 77 MOCK_CONST_METHOD0(IsSyncRequested, bool()); | 76 MOCK_CONST_METHOD0(IsSyncRequested, bool()); |
| 78 MOCK_CONST_METHOD0(waiting_for_auth, bool()); | 77 MOCK_CONST_METHOD0(waiting_for_auth, bool()); |
| 79 MOCK_METHOD1(OnActionableError, void(const syncer::SyncProtocolError&)); | 78 MOCK_METHOD1(OnActionableError, void(const syncer::SyncProtocolError&)); |
| 80 MOCK_CONST_METHOD1(IsDataTypeControllerRunning, bool(syncer::ModelType)); | 79 MOCK_CONST_METHOD1(IsDataTypeControllerRunning, bool(syncer::ModelType)); |
| 81 | 80 |
| 82 // DataTypeManagerObserver mocks. | 81 // DataTypeManagerObserver mocks. |
| 83 MOCK_METHOD1(OnConfigureDone, | 82 MOCK_METHOD1(OnConfigureDone, |
| 84 void(const syncer::DataTypeManager::ConfigureResult&)); | 83 void(const sync_driver::DataTypeManager::ConfigureResult&)); |
| 85 MOCK_METHOD0(OnConfigureStart, void()); | 84 MOCK_METHOD0(OnConfigureStart, void()); |
| 86 | 85 |
| 87 MOCK_CONST_METHOD0(CanSyncStart, bool()); | 86 MOCK_CONST_METHOD0(CanSyncStart, bool()); |
| 88 MOCK_CONST_METHOD0(IsManaged, bool()); | 87 MOCK_CONST_METHOD0(IsManaged, bool()); |
| 89 | 88 |
| 90 MOCK_CONST_METHOD0(IsPassphraseRequired, bool()); | 89 MOCK_CONST_METHOD0(IsPassphraseRequired, bool()); |
| 91 MOCK_CONST_METHOD0(IsPassphraseRequiredForDecryption, bool()); | 90 MOCK_CONST_METHOD0(IsPassphraseRequiredForDecryption, bool()); |
| 92 MOCK_CONST_METHOD0(IsUsingSecondaryPassphrase, bool()); | 91 MOCK_CONST_METHOD0(IsUsingSecondaryPassphrase, bool()); |
| 93 MOCK_CONST_METHOD0(GetPassphraseType, syncer::PassphraseType()); | 92 MOCK_CONST_METHOD0(GetPassphraseType, syncer::PassphraseType()); |
| 94 MOCK_CONST_METHOD0(GetExplicitPassphraseTime, base::Time()); | 93 MOCK_CONST_METHOD0(GetExplicitPassphraseTime, base::Time()); |
| 95 | 94 |
| 96 MOCK_METHOD1(SetDecryptionPassphrase, bool(const std::string& passphrase)); | 95 MOCK_METHOD1(SetDecryptionPassphrase, bool(const std::string& passphrase)); |
| 97 MOCK_METHOD2(SetEncryptionPassphrase, | 96 MOCK_METHOD2(SetEncryptionPassphrase, |
| 98 void(const std::string& passphrase, PassphraseType type)); | 97 void(const std::string& passphrase, PassphraseType type)); |
| 99 | 98 |
| 100 MOCK_METHOD0(OnSetupInProgressHandleDestroyed, void()); | 99 MOCK_METHOD0(OnSetupInProgressHandleDestroyed, void()); |
| 101 }; | 100 }; |
| 102 | 101 |
| 103 } // namespace browser_sync | 102 } // namespace browser_sync |
| 104 | 103 |
| 105 #endif // COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ | 104 #endif // COMPONENTS_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ |
| OLD | NEW |