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

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

Issue 1940153002: Use std::unique_ptr to express ownership of base::Value in PolicyMap::Entry (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: another-fix Created 4 years, 7 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/policy/core/common/policy_statistics_collector_unittest.cc
diff --git a/components/policy/core/common/policy_statistics_collector_unittest.cc b/components/policy/core/common/policy_statistics_collector_unittest.cc
index e316cc87aef428d7b84d8ef131095c21c92fab46..68a4398119b080b77dc786374fc0fac3aa2a287e 100644
--- a/components/policy/core/common/policy_statistics_collector_unittest.cc
+++ b/components/policy/core/common/policy_statistics_collector_unittest.cc
@@ -107,12 +107,9 @@ class PolicyStatisticsCollectorTest : public testing::Test {
}
void SetPolicy(const std::string& name) {
- policy_map_.Set(name,
- POLICY_LEVEL_MANDATORY,
- POLICY_SCOPE_USER,
- POLICY_SOURCE_CLOUD,
- new base::FundamentalValue(true),
- NULL);
+ policy_map_.Set(
+ name, POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER, POLICY_SOURCE_CLOUD,
+ base::WrapUnique(new base::FundamentalValue(true)), nullptr);
}
base::TimeDelta GetFirstDelay() const {

Powered by Google App Engine
This is Rietveld 408576698