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

Unified Diff: components/sync/core_impl/attachments/attachment_service_impl_unittest.cc

Issue 2256733004: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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: components/sync/core_impl/attachments/attachment_service_impl_unittest.cc
diff --git a/components/sync/core_impl/attachments/attachment_service_impl_unittest.cc b/components/sync/core_impl/attachments/attachment_service_impl_unittest.cc
index d12e74eb43d086ca67f2fec36e000d6817409274..91fb01e7f161eb5cc3b5036ad699eb558113a70c 100644
--- a/components/sync/core_impl/attachments/attachment_service_impl_unittest.cc
+++ b/components/sync/core_impl/attachments/attachment_service_impl_unittest.cc
@@ -202,9 +202,9 @@ class AttachmentServiceImplTest : public testing::Test,
void SetUp() override {
network_change_notifier_.reset(net::NetworkChangeNotifier::CreateMock());
- InitializeAttachmentService(
- base::WrapUnique(new MockAttachmentUploader()),
- base::WrapUnique(new MockAttachmentDownloader()), this);
+ InitializeAttachmentService(base::MakeUnique<MockAttachmentUploader>(),
+ base::MakeUnique<MockAttachmentDownloader>(),
+ this);
}
void TearDown() override {
@@ -480,8 +480,8 @@ TEST_F(AttachmentServiceImplTest, UploadAttachments_Success) {
}
TEST_F(AttachmentServiceImplTest, UploadAttachments_Success_NoDelegate) {
- InitializeAttachmentService(base::WrapUnique(new MockAttachmentUploader()),
- base::WrapUnique(new MockAttachmentDownloader()),
+ InitializeAttachmentService(base::MakeUnique<MockAttachmentUploader>(),
+ base::MakeUnique<MockAttachmentDownloader>(),
NULL); // No delegate.
AttachmentIdList attachment_ids;
@@ -551,7 +551,7 @@ TEST_F(AttachmentServiceImplTest, UploadAttachments_AllMissingFromStore) {
TEST_F(AttachmentServiceImplTest, UploadAttachments_NoUploader) {
InitializeAttachmentService(base::WrapUnique<MockAttachmentUploader>(NULL),
- base::WrapUnique(new MockAttachmentDownloader()),
+ base::MakeUnique<MockAttachmentDownloader>(),
this);
AttachmentIdList attachment_ids;

Powered by Google App Engine
This is Rietveld 408576698