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

Unified Diff: chrome/browser/sync/sessions/test_util.cc

Issue 8638001: [Sync] Made some sync session member functions const (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix latent bug in StatusController Created 9 years, 1 month 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
« no previous file with comments | « chrome/browser/sync/sessions/sync_session_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/sessions/test_util.cc
diff --git a/chrome/browser/sync/sessions/test_util.cc b/chrome/browser/sync/sessions/test_util.cc
index 65d307b7387adddf3251381faa0c0a43a029787d..7c0eca938a1b98b708a09517cbd2f62059802633 100644
--- a/chrome/browser/sync/sessions/test_util.cc
+++ b/chrome/browser/sync/sessions/test_util.cc
@@ -10,7 +10,7 @@ namespace test_util {
void SimulateHasMoreToSync(sessions::SyncSession* session,
SyncerStep begin, SyncerStep end) {
- session->status_controller()->update_conflicts_resolved(true);
+ session->mutable_status_controller()->update_conflicts_resolved(true);
ASSERT_TRUE(session->HasMoreToSync());
}
@@ -19,7 +19,7 @@ void SimulateDownloadUpdatesFailed(sessions::SyncSession* session,
// Note that a non-zero value of changes_remaining once a session has
// completed implies that the Syncer was unable to exhaust this count during
// the GetUpdates cycle. This is an indication that an error occurred.
- session->status_controller()->set_num_server_changes_remaining(1);
+ session->mutable_status_controller()->set_num_server_changes_remaining(1);
}
void SimulateCommitFailed(sessions::SyncSession* session,
@@ -30,7 +30,7 @@ void SimulateCommitFailed(sessions::SyncSession* session,
// See implementation of SyncSession::HasMoreToSync.
std::vector<int64> handles;
handles.push_back(1);
- session->status_controller()->set_unsynced_handles(handles);
+ session->mutable_status_controller()->set_unsynced_handles(handles);
}
void SimulateSuccess(sessions::SyncSession* session,
@@ -38,8 +38,8 @@ void SimulateSuccess(sessions::SyncSession* session,
if (session->HasMoreToSync()) {
ADD_FAILURE() << "Shouldn't have more to sync";
}
- ASSERT_EQ(0U, session->status_controller()->num_server_changes_remaining());
- ASSERT_EQ(0U, session->status_controller()->unsynced_handles().size());
+ ASSERT_EQ(0U, session->status_controller().num_server_changes_remaining());
+ ASSERT_EQ(0U, session->status_controller().unsynced_handles().size());
}
void SimulateThrottledImpl(sessions::SyncSession* session,
« no previous file with comments | « chrome/browser/sync/sessions/sync_session_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698