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 SYNC_SYNCABLE_SYNCABLE_MOCK_H_ | 5 #ifndef SYNC_SYNCABLE_SYNCABLE_MOCK_H_ |
6 #define SYNC_SYNCABLE_SYNCABLE_MOCK_H_ | 6 #define SYNC_SYNCABLE_SYNCABLE_MOCK_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 12 matching lines...) Expand all Loading... |
23 explicit MockDirectory(syncer::UnrecoverableErrorHandler* handler); | 23 explicit MockDirectory(syncer::UnrecoverableErrorHandler* handler); |
24 virtual ~MockDirectory(); | 24 virtual ~MockDirectory(); |
25 | 25 |
26 MOCK_METHOD1(GetEntryByHandle, syncable::EntryKernel*(int64)); | 26 MOCK_METHOD1(GetEntryByHandle, syncable::EntryKernel*(int64)); |
27 | 27 |
28 MOCK_METHOD2(set_last_downloadstamp, void(syncer::ModelType, int64)); | 28 MOCK_METHOD2(set_last_downloadstamp, void(syncer::ModelType, int64)); |
29 | 29 |
30 MOCK_METHOD1(GetEntryByClientTag, | 30 MOCK_METHOD1(GetEntryByClientTag, |
31 syncable::EntryKernel*(const std::string&)); | 31 syncable::EntryKernel*(const std::string&)); |
32 | 32 |
33 MOCK_METHOD1(PurgeEntriesWithTypeIn, void(syncer::ModelTypeSet)); | 33 MOCK_METHOD1(PurgeEntriesWithTypeIn, bool(syncer::ModelTypeSet)); |
34 | 34 |
35 private: | 35 private: |
36 syncer::FakeEncryptor encryptor_; | 36 syncer::FakeEncryptor encryptor_; |
37 syncable::NullDirectoryChangeDelegate delegate_; | 37 syncable::NullDirectoryChangeDelegate delegate_; |
38 }; | 38 }; |
39 | 39 |
40 class MockSyncableWriteTransaction : public syncable::WriteTransaction { | 40 class MockSyncableWriteTransaction : public syncable::WriteTransaction { |
41 public: | 41 public: |
42 MockSyncableWriteTransaction( | 42 MockSyncableWriteTransaction( |
43 const tracked_objects::Location& from_here, Directory *directory); | 43 const tracked_objects::Location& from_here, Directory *directory); |
44 }; | 44 }; |
45 | 45 |
46 } // namespace syncable | 46 } // namespace syncable |
47 } // namespace syncer | 47 } // namespace syncer |
48 | 48 |
49 #endif // SYNC_SYNCABLE_SYNCABLE_MOCK_H_ | 49 #endif // SYNC_SYNCABLE_SYNCABLE_MOCK_H_ |
OLD | NEW |