| 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/callback.h" | 6 #include "base/callback.h" |
| 7 #include "base/compiler_specific.h" | 7 #include "base/compiler_specific.h" |
| 8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/test/test_timeouts.h" | 10 #include "base/test/test_timeouts.h" |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 | 128 |
| 129 connection_.reset(new MockConnectionManager(directory(), | 129 connection_.reset(new MockConnectionManager(directory(), |
| 130 &cancelation_signal_)); | 130 &cancelation_signal_)); |
| 131 connection_->SetServerReachable(); | 131 connection_->SetServerReachable(); |
| 132 | 132 |
| 133 model_type_registry_.reset(new ModelTypeRegistry(workers_, directory())); | 133 model_type_registry_.reset(new ModelTypeRegistry(workers_, directory())); |
| 134 | 134 |
| 135 context_.reset(new SyncSessionContext( | 135 context_.reset(new SyncSessionContext( |
| 136 connection_.get(), directory(), | 136 connection_.get(), directory(), |
| 137 extensions_activity_.get(), | 137 extensions_activity_.get(), |
| 138 std::vector<SyncEngineEventListener*>(), NULL, NULL, | 138 std::vector<SyncEngineEventListener*>(), NULL, |
| 139 model_type_registry_.get(), | 139 model_type_registry_.get(), |
| 140 true, // enable keystore encryption | 140 true, // enable keystore encryption |
| 141 false, // force enable pre-commit GU avoidance | 141 false, // force enable pre-commit GU avoidance |
| 142 "fake_invalidator_client_id")); | 142 "fake_invalidator_client_id")); |
| 143 context_->SetRoutingInfo(routing_info_); | 143 context_->SetRoutingInfo(routing_info_); |
| 144 context_->set_notifications_enabled(true); | 144 context_->set_notifications_enabled(true); |
| 145 context_->set_account_name("Test"); | 145 context_->set_account_name("Test"); |
| 146 scheduler_.reset( | 146 scheduler_.reset( |
| 147 new SyncSchedulerImpl("TestSyncScheduler", | 147 new SyncSchedulerImpl("TestSyncScheduler", |
| 148 BackoffDelayProvider::FromDefaults(), | 148 BackoffDelayProvider::FromDefaults(), |
| (...skipping 1235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1384 .WillOnce(DoAll(Invoke(sessions::test_util::SimulateNormalSuccess), | 1384 .WillOnce(DoAll(Invoke(sessions::test_util::SimulateNormalSuccess), |
| 1385 RecordSyncShare(×))); | 1385 RecordSyncShare(×))); |
| 1386 | 1386 |
| 1387 // Run to wait for retrying. | 1387 // Run to wait for retrying. |
| 1388 RunLoop(); | 1388 RunLoop(); |
| 1389 | 1389 |
| 1390 StopSyncScheduler(); | 1390 StopSyncScheduler(); |
| 1391 } | 1391 } |
| 1392 | 1392 |
| 1393 } // namespace syncer | 1393 } // namespace syncer |
| OLD | NEW |