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

Unified Diff: components/sync/model/fake_model_type_service.cc

Issue 2416823003: [Sync] Move some things from core/ to model(_impl)/. (Closed)
Patch Set: Rebase. Created 4 years, 2 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/model/fake_model_type_service.cc
diff --git a/components/sync/model/fake_model_type_service.cc b/components/sync/model/fake_model_type_service.cc
index f90b72178107ccdb7b0ae7b9384f88617f5c7539..6eb0b56451a6040ecc3f77893fc5472027634d98 100644
--- a/components/sync/model/fake_model_type_service.cc
+++ b/components/sync/model/fake_model_type_service.cc
@@ -8,8 +8,8 @@
#include "base/bind.h"
#include "base/memory/ptr_util.h"
-#include "components/sync/core/data_batch_impl.h"
-#include "components/sync/core/simple_metadata_change_list.h"
+#include "components/sync/model/mutable_data_batch.h"
+#include "components/sync/model/simple_metadata_change_list.h"
#include "components/sync/syncable/syncable_util.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -267,7 +267,8 @@ void FakeModelTypeService::GetData(StorageKeyList keys, DataCallback callback) {
service_error_ = SyncError();
return;
}
- std::unique_ptr<DataBatchImpl> batch(new DataBatchImpl());
+
+ auto batch = base::MakeUnique<MutableDataBatch>();
for (const std::string& key : keys) {
DCHECK(db_->HasData(key)) << "No data for " << key;
batch->Put(key, CopyEntityData(db_->GetData(key)));
@@ -281,7 +282,8 @@ void FakeModelTypeService::GetAllData(DataCallback callback) {
service_error_ = SyncError();
return;
}
- std::unique_ptr<DataBatchImpl> batch(new DataBatchImpl());
+
+ auto batch = base::MakeUnique<MutableDataBatch>();
for (const auto& kv : db_->all_data()) {
batch->Put(kv.first, CopyEntityData(*kv.second));
}
« no previous file with comments | « components/sync/device_info/device_info_service_unittest.cc ('k') | components/sync/model/model_type_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698