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

Unified Diff: sync/engine/syncer_unittest.cc

Issue 23809005: sync: Implement per-type GetCommitIds (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments + algorithm improvements Created 7 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: sync/engine/syncer_unittest.cc
diff --git a/sync/engine/syncer_unittest.cc b/sync/engine/syncer_unittest.cc
index 068d86304fb5cb09525a01219eb414784d84e087..4858e043576b80e69547cef9b6c98bf50e9f56d0 100644
--- a/sync/engine/syncer_unittest.cc
+++ b/sync/engine/syncer_unittest.cc
@@ -23,7 +23,7 @@
#include "base/strings/stringprintf.h"
#include "base/time/time.h"
#include "build/build_config.h"
-#include "sync/engine/get_commit_ids_command.h"
+#include "sync/engine/get_commit_ids.h"
#include "sync/engine/net/server_connection_manager.h"
#include "sync/engine/process_updates_command.h"
#include "sync/engine/sync_scheduler_impl.h"
@@ -401,12 +401,7 @@ class SyncerTest : public testing::Test,
GetModelSafeRoutingInfo(&routes);
ModelTypeSet types = GetRoutingInfoTypes(routes);
sessions::OrderedCommitSet output_set(routes);
- GetCommitIdsCommand command(&wtrans, types, limit, &output_set);
- std::set<int64> ready_unsynced_set;
- command.FilterUnreadyEntries(&wtrans, types,
- ModelTypeSet(), false,
- unsynced_handle_view, &ready_unsynced_set);
- command.BuildCommitIds(&wtrans, routes, ready_unsynced_set);
+ GetCommitIds(&wtrans, types, limit, &output_set);
size_t truncated_size = std::min(limit, expected_handle_order.size());
ASSERT_EQ(truncated_size, output_set.Size());
for (size_t i = 0; i < truncated_size; ++i) {

Powered by Google App Engine
This is Rietveld 408576698