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 #include "sync/internal_api/public/test/fake_sync_manager.h" | 5 #include "sync/internal_api/public/test/fake_sync_manager.h" |
6 | 6 |
7 #include <cstddef> | 7 #include <cstddef> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 ChangeDelegate* change_delegate, | 104 ChangeDelegate* change_delegate, |
105 const SyncCredentials& credentials, | 105 const SyncCredentials& credentials, |
106 scoped_ptr<Invalidator> invalidator, | 106 scoped_ptr<Invalidator> invalidator, |
107 const std::string& invalidator_client_id, | 107 const std::string& invalidator_client_id, |
108 const std::string& restored_key_for_bootstrapping, | 108 const std::string& restored_key_for_bootstrapping, |
109 const std::string& restored_keystore_key_for_bootstrapping, | 109 const std::string& restored_keystore_key_for_bootstrapping, |
110 scoped_ptr<InternalComponentsFactory> internal_components_factory, | 110 scoped_ptr<InternalComponentsFactory> internal_components_factory, |
111 Encryptor* encryptor, | 111 Encryptor* encryptor, |
112 UnrecoverableErrorHandler* unrecoverable_error_handler, | 112 UnrecoverableErrorHandler* unrecoverable_error_handler, |
113 ReportUnrecoverableErrorFunction | 113 ReportUnrecoverableErrorFunction |
114 report_unrecoverable_error_function) { | 114 report_unrecoverable_error_function, |
| 115 bool use_oauth2_token) { |
115 sync_task_runner_ = base::ThreadTaskRunnerHandle::Get(); | 116 sync_task_runner_ = base::ThreadTaskRunnerHandle::Get(); |
116 PurgePartiallySyncedTypes(); | 117 PurgePartiallySyncedTypes(); |
117 | 118 |
118 test_user_share_.SetUp(); | 119 test_user_share_.SetUp(); |
119 UserShare* share = test_user_share_.user_share(); | 120 UserShare* share = test_user_share_.user_share(); |
120 for (ModelTypeSet::Iterator it = initial_sync_ended_types_.First(); | 121 for (ModelTypeSet::Iterator it = initial_sync_ended_types_.First(); |
121 it.Good(); it.Inc()) { | 122 it.Good(); it.Inc()) { |
122 TestUserShare::CreateRoot(it.Get(), share); | 123 TestUserShare::CreateRoot(it.Get(), share); |
123 } | 124 } |
124 | 125 |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
303 InvalidatorState state) { | 304 InvalidatorState state) { |
304 DCHECK(sync_task_runner_->RunsTasksOnCurrentThread()); | 305 DCHECK(sync_task_runner_->RunsTasksOnCurrentThread()); |
305 registrar_.UpdateInvalidatorState(state); | 306 registrar_.UpdateInvalidatorState(state); |
306 } | 307 } |
307 | 308 |
308 ModelTypeSet FakeSyncManager::GetLastRefreshRequestTypes() { | 309 ModelTypeSet FakeSyncManager::GetLastRefreshRequestTypes() { |
309 return last_refresh_request_types_; | 310 return last_refresh_request_types_; |
310 } | 311 } |
311 | 312 |
312 } // namespace syncer | 313 } // namespace syncer |
OLD | NEW |