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_INTERNAL_API_PUBLIC_TEST_FAKE_SYNC_MANAGER_H_ | 5 #ifndef SYNC_INTERNAL_API_PUBLIC_TEST_FAKE_SYNC_MANAGER_H_ |
6 #define SYNC_INTERNAL_API_PUBLIC_TEST_FAKE_SYNC_MANAGER_H_ | 6 #define SYNC_INTERNAL_API_PUBLIC_TEST_FAKE_SYNC_MANAGER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "base/observer_list.h" | 11 #include "base/observer_list.h" |
12 #include "sync/internal_api/public/sync_manager.h" | 12 #include "sync/internal_api/public/sync_manager.h" |
| 13 #include "sync/internal_api/public/test/test_user_share.h" |
13 #include "sync/notifier/invalidator_registrar.h" | 14 #include "sync/notifier/invalidator_registrar.h" |
14 | 15 |
15 namespace base { | 16 namespace base { |
16 class SequencedTaskRunner; | 17 class SequencedTaskRunner; |
17 } | 18 } |
18 | 19 |
19 namespace syncer { | 20 namespace syncer { |
20 | 21 |
21 class FakeSyncEncryptionHandler; | 22 class FakeSyncEncryptionHandler; |
22 | 23 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 | 66 |
66 // SyncManager implementation. | 67 // SyncManager implementation. |
67 // Note: we treat whatever message loop this is called from as the sync | 68 // Note: we treat whatever message loop this is called from as the sync |
68 // loop for purposes of callbacks. | 69 // loop for purposes of callbacks. |
69 virtual void Init( | 70 virtual void Init( |
70 const FilePath& database_location, | 71 const FilePath& database_location, |
71 const WeakHandle<JsEventHandler>& event_handler, | 72 const WeakHandle<JsEventHandler>& event_handler, |
72 const std::string& sync_server_and_path, | 73 const std::string& sync_server_and_path, |
73 int sync_server_port, | 74 int sync_server_port, |
74 bool use_ssl, | 75 bool use_ssl, |
75 const scoped_refptr<base::TaskRunner>& blocking_task_runner, | |
76 scoped_ptr<HttpPostProviderFactory> post_factory, | 76 scoped_ptr<HttpPostProviderFactory> post_factory, |
77 const std::vector<ModelSafeWorker*>& workers, | 77 const std::vector<ModelSafeWorker*>& workers, |
78 ExtensionsActivityMonitor* extensions_activity_monitor, | 78 ExtensionsActivityMonitor* extensions_activity_monitor, |
79 ChangeDelegate* change_delegate, | 79 ChangeDelegate* change_delegate, |
80 const SyncCredentials& credentials, | 80 const SyncCredentials& credentials, |
81 scoped_ptr<Invalidator> invalidator, | 81 scoped_ptr<Invalidator> invalidator, |
82 const std::string& restored_key_for_bootstrapping, | 82 const std::string& restored_key_for_bootstrapping, |
83 const std::string& restored_keystore_key_for_bootstrapping, | 83 const std::string& restored_keystore_key_for_bootstrapping, |
84 scoped_ptr<InternalComponentsFactory> internal_components_factory, | 84 scoped_ptr<InternalComponentsFactory> internal_components_factory, |
85 Encryptor* encryptor, | 85 Encryptor* encryptor, |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 // The set of types that have been downloaded. | 142 // The set of types that have been downloaded. |
143 ModelTypeSet downloaded_types_; | 143 ModelTypeSet downloaded_types_; |
144 // The set of types that have been enabled. | 144 // The set of types that have been enabled. |
145 ModelTypeSet enabled_types_; | 145 ModelTypeSet enabled_types_; |
146 | 146 |
147 // Faked invalidator state. | 147 // Faked invalidator state. |
148 InvalidatorRegistrar registrar_; | 148 InvalidatorRegistrar registrar_; |
149 | 149 |
150 scoped_ptr<FakeSyncEncryptionHandler> fake_encryption_handler_; | 150 scoped_ptr<FakeSyncEncryptionHandler> fake_encryption_handler_; |
151 | 151 |
| 152 TestUserShare test_user_share_; |
| 153 |
152 DISALLOW_COPY_AND_ASSIGN(FakeSyncManager); | 154 DISALLOW_COPY_AND_ASSIGN(FakeSyncManager); |
153 }; | 155 }; |
154 | 156 |
155 } // namespace syncer | 157 } // namespace syncer |
156 | 158 |
157 #endif // SYNC_INTERNAL_API_PUBLIC_TEST_FAKE_SYNC_MANAGER_H_ | 159 #endif // SYNC_INTERNAL_API_PUBLIC_TEST_FAKE_SYNC_MANAGER_H_ |
OLD | NEW |