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

Unified Diff: components/policy/core/common/policy_loader_win_unittest.cc

Issue 1902633006: Convert //components/policy from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments and use namespace alias 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
« no previous file with comments | « components/policy/core/common/policy_loader_win.cc ('k') | components/policy/core/common/policy_map.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/policy/core/common/policy_loader_win_unittest.cc
diff --git a/components/policy/core/common/policy_loader_win_unittest.cc b/components/policy/core/common/policy_loader_win_unittest.cc
index 92d03071a75809d6ad02686a79ce32d9c2d798fa..11521ee232bdc67157397baea9a9026500c0855c 100644
--- a/components/policy/core/common/policy_loader_win_unittest.cc
+++ b/components/policy/core/common/policy_loader_win_unittest.cc
@@ -351,7 +351,7 @@ ConfigurationPolicyProvider* RegistryTestHarness::CreateProvider(
SchemaRegistry* registry,
scoped_refptr<base::SequencedTaskRunner> task_runner) {
base::win::SetDomainStateForTesting(true);
- scoped_ptr<AsyncPolicyLoader> loader(
+ std::unique_ptr<AsyncPolicyLoader> loader(
new PolicyLoaderWin(task_runner, kTestPolicyKey, this));
return new AsyncPolicyProvider(registry, std::move(loader));
}
@@ -484,7 +484,7 @@ void PRegTestHarness::SetUp() {
ConfigurationPolicyProvider* PRegTestHarness::CreateProvider(
SchemaRegistry* registry,
scoped_refptr<base::SequencedTaskRunner> task_runner) {
- scoped_ptr<AsyncPolicyLoader> loader(
+ std::unique_ptr<AsyncPolicyLoader> loader(
new PolicyLoaderWin(task_runner, kTestPolicyKey, this));
return new AsyncPolicyProvider(registry, std::move(loader));
}
@@ -749,7 +749,7 @@ class PolicyLoaderWinTest : public PolicyTestBase,
bool Matches(const PolicyBundle& expected) {
PolicyLoaderWin loader(loop_.task_runner(), kTestPolicyKey,
gpo_list_provider_);
- scoped_ptr<PolicyBundle> loaded(
+ std::unique_ptr<PolicyBundle> loaded(
loader.InitialLoad(schema_registry_.schema_map()));
return loaded->Equals(expected);
}
@@ -777,7 +777,7 @@ class PolicyLoaderWinTest : public PolicyTestBase,
expected_policy.SetBoolean(test_keys::kKeyBoolean, true);
expected_policy.SetString(test_keys::kKeyString, "GPO");
expected_policy.SetInteger(test_keys::kKeyInteger, 42);
- scoped_ptr<base::ListValue> list(new base::ListValue());
+ std::unique_ptr<base::ListValue> list(new base::ListValue());
list->AppendString("GPO 1");
list->AppendString("GPO 2");
expected_policy.Set(test_keys::kKeyStringList, list.release());
« no previous file with comments | « components/policy/core/common/policy_loader_win.cc ('k') | components/policy/core/common/policy_map.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698