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

Unified Diff: chrome/browser/extensions/app_data_migrator_unittest.cc

Issue 1871713002: Convert //chrome/browser/extensions from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and fix header Created 4 years, 8 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: chrome/browser/extensions/app_data_migrator_unittest.cc
diff --git a/chrome/browser/extensions/app_data_migrator_unittest.cc b/chrome/browser/extensions/app_data_migrator_unittest.cc
index eb4b22b47e3a2e867e246f702bf0b641f273d937..ad9f702a176f190e51fdaa8087ca1d0432e1ed0a 100644
--- a/chrome/browser/extensions/app_data_migrator_unittest.cc
+++ b/chrome/browser/extensions/app_data_migrator_unittest.cc
@@ -27,7 +27,7 @@
#include "testing/gtest/include/gtest/gtest.h"
namespace {
-scoped_ptr<TestingProfile> GetTestingProfile() {
+std::unique_ptr<TestingProfile> GetTestingProfile() {
TestingProfile::Builder profile_builder;
return profile_builder.Build();
}
@@ -43,7 +43,7 @@ class AppDataMigratorTest : public testing::Test {
void SetUp() override {
profile_ = GetTestingProfile();
registry_ = ExtensionRegistry::Get(profile_.get());
- migrator_ = scoped_ptr<AppDataMigrator>(
+ migrator_ = std::unique_ptr<AppDataMigrator>(
new AppDataMigrator(profile_.get(), registry_));
default_partition_ =
@@ -55,7 +55,7 @@ class AppDataMigratorTest : public testing::Test {
default_fs_context_ = default_partition_->GetFileSystemContext();
- url_request_context_ = scoped_ptr<content::MockBlobURLRequestContext>(
+ url_request_context_ = std::unique_ptr<content::MockBlobURLRequestContext>(
new content::MockBlobURLRequestContext(default_fs_context_));
}
@@ -63,13 +63,13 @@ class AppDataMigratorTest : public testing::Test {
protected:
content::TestBrowserThreadBundle thread_bundle_;
- scoped_ptr<TestingProfile> profile_;
- scoped_ptr<AppDataMigrator> migrator_;
+ std::unique_ptr<TestingProfile> profile_;
+ std::unique_ptr<AppDataMigrator> migrator_;
content::StoragePartition* default_partition_;
ExtensionRegistry* registry_;
storage::FileSystemContext* default_fs_context_;
content::IndexedDBContext* idb_context_;
- scoped_ptr<content::MockBlobURLRequestContext> url_request_context_;
+ std::unique_ptr<content::MockBlobURLRequestContext> url_request_context_;
};
scoped_refptr<const Extension> GetTestExtension(bool platform_app) {
@@ -183,7 +183,7 @@ void GenerateTestFiles(content::MockBlobURLRequestContext* url_request_context,
void VerifyFileContents(base::File file,
const base::Closure& on_close_callback) {
ASSERT_EQ(14, file.GetLength());
- scoped_ptr<char[]> buffer(new char[15]);
+ std::unique_ptr<char[]> buffer(new char[15]);
file.Read(0, buffer.get(), 14);
buffer.get()[14] = 0;
« no previous file with comments | « chrome/browser/extensions/app_data_migrator.cc ('k') | chrome/browser/extensions/background_app_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698