Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(623)

Side by Side Diff: sync/engine/syncer_unittest.cc

Issue 12256033: Separate invalidator and sync client ID (part 1/2) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « sync/engine/syncer_proto_util.cc ('k') | sync/internal_api/internal_components_factory_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 // Syncer unit tests. Unfortunately a lot of these tests 5 // Syncer unit tests. Unfortunately a lot of these tests
6 // are outdated and need to be reworked and updated. 6 // are outdated and need to be reworked and updated.
7 7
8 #include <algorithm> 8 #include <algorithm>
9 #include <limits> 9 #include <limits>
10 #include <list> 10 #include <list>
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 GetModelSafeRoutingInfo(&routing_info); 219 GetModelSafeRoutingInfo(&routing_info);
220 GetWorkers(&workers); 220 GetWorkers(&workers);
221 221
222 throttled_data_type_tracker_.reset(new ThrottledDataTypeTracker(NULL)); 222 throttled_data_type_tracker_.reset(new ThrottledDataTypeTracker(NULL));
223 223
224 context_.reset( 224 context_.reset(
225 new SyncSessionContext( 225 new SyncSessionContext(
226 mock_server_.get(), directory(), workers, 226 mock_server_.get(), directory(), workers,
227 &extensions_activity_monitor_, throttled_data_type_tracker_.get(), 227 &extensions_activity_monitor_, throttled_data_type_tracker_.get(),
228 listeners, NULL, &traffic_recorder_, 228 listeners, NULL, &traffic_recorder_,
229 true /* enable keystore encryption */)); 229 true, // enable keystore encryption
230 "fake_invalidator_client_id"));
230 context_->set_routing_info(routing_info); 231 context_->set_routing_info(routing_info);
231 syncer_ = new Syncer(); 232 syncer_ = new Syncer();
232 session_.reset(MakeSession()); 233 session_.reset(MakeSession());
233 234
234 syncable::ReadTransaction trans(FROM_HERE, directory()); 235 syncable::ReadTransaction trans(FROM_HERE, directory());
235 syncable::Directory::ChildHandles children; 236 syncable::Directory::ChildHandles children;
236 directory()->GetChildHandlesById(&trans, trans.root_id(), &children); 237 directory()->GetChildHandlesById(&trans, trans.root_id(), &children);
237 ASSERT_EQ(0u, children.size()); 238 ASSERT_EQ(0u, children.size());
238 saw_syncer_event_ = false; 239 saw_syncer_event_ = false;
239 root_id_ = TestIdFactory::root(); 240 root_id_ = TestIdFactory::root();
(...skipping 4677 matching lines...) Expand 10 before | Expand all | Expand 10 after
4917 4918
4918 TEST_F(SyncerPositionTiebreakingTest, MidLowHigh) { 4919 TEST_F(SyncerPositionTiebreakingTest, MidLowHigh) {
4919 Add(mid_id_); 4920 Add(mid_id_);
4920 Add(low_id_); 4921 Add(low_id_);
4921 Add(high_id_); 4922 Add(high_id_);
4922 SyncShareNudge(); 4923 SyncShareNudge();
4923 ExpectLocalOrderIsByServerId(); 4924 ExpectLocalOrderIsByServerId();
4924 } 4925 }
4925 4926
4926 } // namespace syncer 4927 } // namespace syncer
OLDNEW
« no previous file with comments | « sync/engine/syncer_proto_util.cc ('k') | sync/internal_api/internal_components_factory_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698