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

Unified Diff: components/browser_sync/profile_sync_service_autofill_unittest.cc

Issue 2422253002: [Sync] Rewriting ".reset(new" pattern to use "= base::MakeUnique" instead. (Closed)
Patch Set: Fixing compile. 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/browser_sync/profile_sync_service_autofill_unittest.cc
diff --git a/components/browser_sync/profile_sync_service_autofill_unittest.cc b/components/browser_sync/profile_sync_service_autofill_unittest.cc
index 559b895a8bcf051ddbc2d1c33291d6e72128667e..24627d795191dc2af599896e8cf5870fcf2b3421 100644
--- a/components/browser_sync/profile_sync_service_autofill_unittest.cc
+++ b/components/browser_sync/profile_sync_service_autofill_unittest.cc
@@ -327,8 +327,8 @@ class WebDataServiceFake : public AutofillWebDataService {
const base::Callback<void(syncer::ModelType)>& on_sync_started) {
ASSERT_TRUE(db_thread_->RunsTasksOnCurrentThread());
// These services are deleted in DestroySyncableService().
- backend_.reset(new MockAutofillBackend(GetDatabase(), on_changed_callback,
- on_sync_started, ui_thread_.get()));
+ backend_ = base::MakeUnique<MockAutofillBackend>(
+ GetDatabase(), on_changed_callback, on_sync_started, ui_thread_.get());
AutocompleteSyncableService::CreateForWebDataServiceAndBackend(
this, backend_.get());
AutofillProfileSyncableService::CreateForWebDataServiceAndBackend(
@@ -402,7 +402,7 @@ class ProfileSyncServiceAutofillTest
profile_sync_service_bundle()->set_db_thread(
data_type_thread()->task_runner());
- web_database_.reset(new WebDatabaseFake(&autofill_table_));
+ web_database_ = base::MakeUnique<WebDatabaseFake>(&autofill_table_);
web_data_wrapper_ = base::MakeUnique<MockWebDataServiceWrapper>(
new WebDataServiceFake(base::ThreadTaskRunnerHandle::Get(),
data_type_thread()->task_runner()),
« no previous file with comments | « components/browser_sync/profile_sync_service.cc ('k') | components/browser_sync/profile_sync_service_bookmark_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698