| Index: chrome/common/extensions/manifest_tests/extension_manifests_platformapp_unittest.cc
|
| diff --git a/chrome/common/extensions/manifest_tests/extension_manifests_platformapp_unittest.cc b/chrome/common/extensions/manifest_tests/extension_manifests_platformapp_unittest.cc
|
| index 9a71ab9ab8855520bc0b72b2e0e40d5b5f489c86..2ef9ac4a1071339e20c70afdf29dbf81c2b0bd60 100644
|
| --- a/chrome/common/extensions/manifest_tests/extension_manifests_platformapp_unittest.cc
|
| +++ b/chrome/common/extensions/manifest_tests/extension_manifests_platformapp_unittest.cc
|
| @@ -2,10 +2,13 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| +#include <memory>
|
| +
|
| #include "base/command_line.h"
|
| #include "base/json/json_file_value_serializer.h"
|
| #include "base/macros.h"
|
| #include "base/memory/linked_ptr.h"
|
| +#include "base/memory/ptr_util.h"
|
| #include "chrome/common/extensions/manifest_tests/chrome_manifest_test.h"
|
| #include "extensions/common/error_utils.h"
|
| #include "extensions/common/features/simple_feature.h"
|
| @@ -115,10 +118,10 @@ TEST_F(PlatformAppsManifestTest, CertainApisRequirePlatformApps) {
|
| // testing. The requirements are that (1) it be a valid platform app, and (2)
|
| // it contain no permissions dictionary.
|
| std::string error;
|
| - scoped_ptr<base::DictionaryValue> manifest(
|
| + std::unique_ptr<base::DictionaryValue> manifest(
|
| LoadManifest("init_valid_platform_app.json", &error));
|
|
|
| - std::vector<scoped_ptr<ManifestData>> manifests;
|
| + std::vector<std::unique_ptr<ManifestData>> manifests;
|
| // Create each manifest.
|
| for (const char* api_name : kPlatformAppExperimentalApis) {
|
| // DictionaryValue will take ownership of this ListValue.
|
| @@ -127,10 +130,10 @@ TEST_F(PlatformAppsManifestTest, CertainApisRequirePlatformApps) {
|
| permissions->Append(new base::StringValue(api_name));
|
| manifest->Set("permissions", permissions);
|
| manifests.push_back(
|
| - make_scoped_ptr(new ManifestData(manifest->CreateDeepCopy(), "")));
|
| + base::WrapUnique(new ManifestData(manifest->CreateDeepCopy(), "")));
|
| }
|
| // First try to load without any flags. This should warn for every API.
|
| - for (const scoped_ptr<ManifestData>& manifest : manifests) {
|
| + for (const std::unique_ptr<ManifestData>& manifest : manifests) {
|
| LoadAndExpectWarning(
|
| *manifest,
|
| "'experimental' requires the 'experimental-extension-apis' "
|
| @@ -140,7 +143,7 @@ TEST_F(PlatformAppsManifestTest, CertainApisRequirePlatformApps) {
|
| // Now try again with the experimental flag set.
|
| base::CommandLine::ForCurrentProcess()->AppendSwitch(
|
| switches::kEnableExperimentalExtensionApis);
|
| - for (const scoped_ptr<ManifestData>& manifest : manifests)
|
| + for (const std::unique_ptr<ManifestData>& manifest : manifests)
|
| LoadAndExpectSuccess(*manifest);
|
| }
|
|
|
|
|