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

Unified Diff: chrome/browser/sync/engine/syncer_unittest.cc

Issue 6104003: sync: use progress markers instead of timestamps during GetUpdates (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: For review Created 9 years, 11 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: chrome/browser/sync/engine/syncer_unittest.cc
diff --git a/chrome/browser/sync/engine/syncer_unittest.cc b/chrome/browser/sync/engine/syncer_unittest.cc
index 27725b37021f3cc50dfd8e6edd9f5807aa23a59a..4919c4f36153c38f45ff064a7f9e848592878438 100644
--- a/chrome/browser/sync/engine/syncer_unittest.cc
+++ b/chrome/browser/sync/engine/syncer_unittest.cc
@@ -3578,14 +3578,20 @@ TEST_F(SyncerTest, LongChangelistWithApplicationConflict) {
mock_server_->SetChangesRemaining(DEPTH - 1);
syncer_->SyncShare(session_.get());
- // Very long changelist. We should never be stuck.
+ // Buffer up a very long series of downloads.
+ // We should never be stuck (conflict resolution shouldn't
+ // kick in so long as we're making forward progress).
for (int i = 0; i < DEPTH; i++) {
- mock_server_->SetNewTimestamp(i);
+ mock_server_->NextUpdateBatch();
+ mock_server_->SetNewTimestamp(i + 1);
mock_server_->SetChangesRemaining(DEPTH - i);
- syncer_->SyncShare(session_.get());
- EXPECT_FALSE(session_->status_controller()->syncer_status().syncer_stuck);
+ }
- // Ensure our folder hasn't somehow applied.
+ syncer_->SyncShare(session_.get());
+ EXPECT_FALSE(session_->status_controller()->syncer_status().syncer_stuck);
+
+ // Ensure our folder hasn't somehow applied.
+ {
ReadTransaction trans(dir, __FILE__, __LINE__);
Entry child(&trans, GET_BY_ID, stuck_entry_id);
EXPECT_TRUE(child.good());

Powered by Google App Engine
This is Rietveld 408576698