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

Unified Diff: components/sync/test/engine/mock_model_type_worker.h

Issue 2935583002: [Sync] Implement support for untracking new entities (Closed)
Patch Set: add comments Created 3 years, 6 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: components/sync/test/engine/mock_model_type_worker.h
diff --git a/components/sync/test/engine/mock_model_type_worker.h b/components/sync/test/engine/mock_model_type_worker.h
index 0e3cac7770c8338d7aa6ced67f2a487bfd3f4dc6..d493857262d5a0b9779a14d7a4ecb7434536cc1f 100644
--- a/components/sync/test/engine/mock_model_type_worker.h
+++ b/components/sync/test/engine/mock_model_type_worker.h
@@ -66,6 +66,7 @@ class MockModelTypeWorker : public CommitQueue {
const sync_pb::EntitySpecifics& specifics,
int64_t version_offset,
const std::string& ekn);
+ void UpdateFromServer(const UpdateResponseDataList& updates);
// Returns an UpdateResponseData representing an update received from
// the server. Updates server state accordingly.
@@ -81,6 +82,12 @@ class MockModelTypeWorker : public CommitQueue {
int64_t version_offset,
const std::string& ekn);
+ // Mostly same as GenerateUpdateData above, but set 1 as |version_offset|, and
+ // use model_type_state_.encryption_key_name() as |ekn|.
+ UpdateResponseData GenerateUpdateData(
+ const std::string& tag_hash,
+ const sync_pb::EntitySpecifics& specifics);
+
// Triggers a server-side deletion of the entity with |tag_hash|; updates
// server state accordingly.
void TombstoneFromServer(const std::string& tag_hash);

Powered by Google App Engine
This is Rietveld 408576698