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

Unified Diff: content/browser/storage_partition_impl_unittest.cc

Issue 2256173002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Replace a WrapUnique() nested inside a MakeUnique() Created 4 years, 3 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: content/browser/storage_partition_impl_unittest.cc
diff --git a/content/browser/storage_partition_impl_unittest.cc b/content/browser/storage_partition_impl_unittest.cc
index 99fc51f75dc0a7182a1d1aad802ce4154ec16625..26ec5d432265267f1f85c3f2099359f8e98f8ec7 100644
--- a/content/browser/storage_partition_impl_unittest.cc
+++ b/content/browser/storage_partition_impl_unittest.cc
@@ -301,8 +301,8 @@ class RemovePluginPrivateDataTester {
filesystem_context_->GetAsyncFileUtil(
storage::kFileSystemTypePluginPrivate);
std::unique_ptr<storage::FileSystemOperationContext> operation_context =
- base::WrapUnique(
- new storage::FileSystemOperationContext(filesystem_context_));
+ base::MakeUnique<storage::FileSystemOperationContext>(
+ filesystem_context_);
async_file_util->CreateOrOpen(
std::move(operation_context), clearkey_file_,
base::File::FLAG_OPEN | base::File::FLAG_WRITE,
@@ -347,8 +347,8 @@ class RemovePluginPrivateDataTester {
storage::AsyncFileUtil* file_util = filesystem_context_->GetAsyncFileUtil(
storage::kFileSystemTypePluginPrivate);
std::unique_ptr<storage::FileSystemOperationContext> operation_context =
- base::WrapUnique(
- new storage::FileSystemOperationContext(filesystem_context_));
+ base::MakeUnique<storage::FileSystemOperationContext>(
+ filesystem_context_);
operation_context->set_allowed_bytes_growth(
storage::QuotaManager::kNoLimit);
file_util->EnsureFileExists(
@@ -367,8 +367,8 @@ class RemovePluginPrivateDataTester {
storage::AsyncFileUtil* file_util = filesystem_context_->GetAsyncFileUtil(
storage::kFileSystemTypePluginPrivate);
std::unique_ptr<storage::FileSystemOperationContext> operation_context =
- base::WrapUnique(
- new storage::FileSystemOperationContext(filesystem_context_));
+ base::MakeUnique<storage::FileSystemOperationContext>(
+ filesystem_context_);
file_util->Touch(std::move(operation_context), file_url, time_stamp,
time_stamp,
base::Bind(&RemovePluginPrivateDataTester::OnFileTouched,

Powered by Google App Engine
This is Rietveld 408576698