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

Unified Diff: chrome/browser/sync/glue/sync_backend_host_unittest.cc

Issue 10837214: Refactor ModelTypePayloadMap and ObjectIdPayloadMap to StateMaps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 4 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/glue/sync_backend_host_unittest.cc
diff --git a/chrome/browser/sync/glue/sync_backend_host_unittest.cc b/chrome/browser/sync/glue/sync_backend_host_unittest.cc
index 16770e7d24457f71e23406ce139d85cb65f6a66d..1b78df0bb6b3d83529b12a3185729e68296e873e 100644
--- a/chrome/browser/sync/glue/sync_backend_host_unittest.cc
+++ b/chrome/browser/sync/glue/sync_backend_host_unittest.cc
@@ -62,7 +62,7 @@ class MockSyncFrontend : public SyncFrontend {
MOCK_METHOD1(OnNotificationsDisabled,
void(syncer::NotificationsDisabledReason));
MOCK_METHOD2(OnIncomingNotification,
- void(const syncer::ObjectIdPayloadMap&,
+ void(const syncer::ObjectIdStateMap&,
syncer::IncomingNotificationSource));
MOCK_METHOD2(OnBackendInitialized,
void(const syncer::WeakHandle<syncer::JsBackend>&, bool));
@@ -584,16 +584,16 @@ TEST_F(SyncBackendHostTest, Invalidate) {
syncer::ObjectIdSet ids;
ids.insert(invalidation::ObjectId(1, "id1"));
ids.insert(invalidation::ObjectId(2, "id2"));
- const syncer::ObjectIdPayloadMap& id_payloads =
- syncer::ObjectIdSetToPayloadMap(ids, "payload");
+ const syncer::ObjectIdStateMap& id_state_map =
+ syncer::ObjectIdSetToStateMap(ids, "payload");
EXPECT_CALL(
mock_frontend_,
- OnIncomingNotification(id_payloads, syncer::REMOTE_NOTIFICATION))
+ OnIncomingNotification(id_state_map, syncer::REMOTE_NOTIFICATION))
.WillOnce(InvokeWithoutArgs(QuitMessageLoop));
backend_->UpdateRegisteredInvalidationIds(ids);
- fake_manager_->Invalidate(id_payloads, syncer::REMOTE_NOTIFICATION);
+ fake_manager_->Invalidate(id_state_map, syncer::REMOTE_NOTIFICATION);
ui_loop_.PostDelayedTask(
FROM_HERE, ui_loop_.QuitClosure(), TestTimeouts::action_timeout());
ui_loop_.Run();
@@ -649,9 +649,9 @@ TEST_F(SyncBackendHostTest, NotificationsAfterStopSyncingForShutdown) {
// Should not trigger anything.
fake_manager_->DisableNotifications(syncer::TRANSIENT_NOTIFICATION_ERROR);
fake_manager_->EnableNotifications();
- const syncer::ObjectIdPayloadMap& id_payloads =
- syncer::ObjectIdSetToPayloadMap(ids, "payload");
- fake_manager_->Invalidate(id_payloads, syncer::REMOTE_NOTIFICATION);
+ const syncer::ObjectIdStateMap& id_state_map =
+ syncer::ObjectIdSetToStateMap(ids, "payload");
+ fake_manager_->Invalidate(id_state_map, syncer::REMOTE_NOTIFICATION);
// Make sure the above calls take effect before we continue.
fake_manager_->WaitForSyncThread();

Powered by Google App Engine
This is Rietveld 408576698