| 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 CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ | 5 #ifndef CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ |
| 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ | 6 #define CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
| 12 #include "base/string16.h" | 12 #include "base/string16.h" |
| 13 #include "chrome/browser/sync/glue/change_processor.h" | 13 #include "chrome/browser/sync/glue/change_processor.h" |
| 14 #include "chrome/browser/sync/glue/data_type_controller.h" | 14 #include "chrome/browser/sync/glue/data_type_controller.h" |
| 15 #include "chrome/browser/sync/profile_sync_service.h" | 15 #include "chrome/browser/sync/profile_sync_service.h" |
| 16 #include "chrome/common/net/gaia/google_service_auth_error.h" | 16 #include "chrome/common/net/gaia/google_service_auth_error.h" |
| 17 #include "chrome/test/base/testing_profile.h" | 17 #include "chrome/test/base/testing_profile.h" |
| 18 #include "sync/internal_api/public/syncable/model_type.h" | 18 #include "sync/internal_api/public/base/model_type.h" |
| 19 #include "sync/protocol/sync_protocol_error.h" | 19 #include "sync/protocol/sync_protocol_error.h" |
| 20 #include "testing/gmock/include/gmock/gmock.h" | 20 #include "testing/gmock/include/gmock/gmock.h" |
| 21 | 21 |
| 22 class ProfileSyncServiceMock : public ProfileSyncService { | 22 class ProfileSyncServiceMock : public ProfileSyncService { |
| 23 public: | 23 public: |
| 24 // no-arg constructor provided so TestingProfile can use NiceMock. | 24 // no-arg constructor provided so TestingProfile can use NiceMock. |
| 25 ProfileSyncServiceMock(); | 25 ProfileSyncServiceMock(); |
| 26 explicit ProfileSyncServiceMock(Profile* profile); | 26 explicit ProfileSyncServiceMock(Profile* profile); |
| 27 virtual ~ProfileSyncServiceMock(); | 27 virtual ~ProfileSyncServiceMock(); |
| 28 | 28 |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 MOCK_CONST_METHOD0(IsPassphraseRequired, bool()); | 96 MOCK_CONST_METHOD0(IsPassphraseRequired, bool()); |
| 97 MOCK_CONST_METHOD0(IsPassphraseRequiredForDecryption, bool()); | 97 MOCK_CONST_METHOD0(IsPassphraseRequiredForDecryption, bool()); |
| 98 MOCK_CONST_METHOD0(IsUsingSecondaryPassphrase, bool()); | 98 MOCK_CONST_METHOD0(IsUsingSecondaryPassphrase, bool()); |
| 99 | 99 |
| 100 MOCK_METHOD1(SetDecryptionPassphrase, bool(const std::string& passphrase)); | 100 MOCK_METHOD1(SetDecryptionPassphrase, bool(const std::string& passphrase)); |
| 101 MOCK_METHOD2(SetEncryptionPassphrase, void(const std::string& passphrase, | 101 MOCK_METHOD2(SetEncryptionPassphrase, void(const std::string& passphrase, |
| 102 PassphraseType type)); | 102 PassphraseType type)); |
| 103 }; | 103 }; |
| 104 | 104 |
| 105 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ | 105 #endif // CHROME_BROWSER_SYNC_PROFILE_SYNC_SERVICE_MOCK_H_ |
| OLD | NEW |