Index: components/policy/core/browser/configuration_policy_handler_unittest.cc |
diff --git a/components/policy/core/browser/configuration_policy_handler_unittest.cc b/components/policy/core/browser/configuration_policy_handler_unittest.cc |
index 36c9c2a485440f60b6eb577c34a22b972a528f25..db30b0f1c51ae301ddd95ec9e23bae71f67957ee 100644 |
--- a/components/policy/core/browser/configuration_policy_handler_unittest.cc |
+++ b/components/policy/core/browser/configuration_policy_handler_unittest.cc |
@@ -79,9 +79,11 @@ TEST(StringToIntEnumListPolicyHandlerTest, CheckPolicySettings) { |
EXPECT_FALSE(errors.empty()); |
EXPECT_FALSE(errors.GetErrors(kTestPolicy).empty()); |
- policy_map.Set(kTestPolicy, POLICY_LEVEL_MANDATORY, |
+ policy_map.Set(kTestPolicy, |
+ POLICY_LEVEL_MANDATORY, |
POLICY_SCOPE_USER, |
- base::Value::CreateStringValue("no list"), NULL); |
+ new base::StringValue("no list"), |
+ NULL); |
errors.Clear(); |
EXPECT_FALSE(handler.CheckPolicySettings(policy_map, &errors)); |
EXPECT_FALSE(errors.empty()); |
@@ -180,8 +182,10 @@ TEST(IntRangePolicyHandler, CheckPolicySettingsClamp) { |
// Check that an entirely invalid value is rejected and yields an error |
// message. |
policy_map.Set(kTestPolicy, |
- POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER, |
- base::Value::CreateStringValue("invalid"), NULL); |
+ POLICY_LEVEL_MANDATORY, |
+ POLICY_SCOPE_USER, |
+ new base::StringValue("invalid"), |
+ NULL); |
errors.Clear(); |
EXPECT_FALSE(handler.CheckPolicySettings(policy_map, &errors)); |
EXPECT_FALSE(errors.empty()); |
@@ -245,8 +249,11 @@ TEST(IntRangePolicyHandler, CheckPolicySettingsDontClamp) { |
// Check that an entirely invalid value is rejected and yields an error |
// message. |
- policy_map.Set(kTestPolicy, POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER, |
- base::Value::CreateStringValue("invalid"), NULL); |
+ policy_map.Set(kTestPolicy, |
+ POLICY_LEVEL_MANDATORY, |
+ POLICY_SCOPE_USER, |
+ new base::StringValue("invalid"), |
+ NULL); |
errors.Clear(); |
EXPECT_FALSE(handler.CheckPolicySettings(policy_map, &errors)); |
EXPECT_FALSE(errors.empty()); |
@@ -425,8 +432,11 @@ TEST(IntPercentageToDoublePolicyHandler, CheckPolicySettingsClamp) { |
// Check that an entirely invalid value is rejected and yields an error |
// message. |
- policy_map.Set(kTestPolicy, POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER, |
- base::Value::CreateStringValue("invalid"), NULL); |
+ policy_map.Set(kTestPolicy, |
+ POLICY_LEVEL_MANDATORY, |
+ POLICY_SCOPE_USER, |
+ new base::StringValue("invalid"), |
+ NULL); |
errors.Clear(); |
EXPECT_FALSE(handler.CheckPolicySettings(policy_map, &errors)); |
EXPECT_FALSE(errors.empty()); |
@@ -491,8 +501,11 @@ TEST(IntPercentageToDoublePolicyHandler, CheckPolicySettingsDontClamp) { |
// Check that an entirely invalid value is rejected and yields an error |
// message. |
- policy_map.Set(kTestPolicy, POLICY_LEVEL_MANDATORY, POLICY_SCOPE_USER, |
- base::Value::CreateStringValue("invalid"), NULL); |
+ policy_map.Set(kTestPolicy, |
+ POLICY_LEVEL_MANDATORY, |
+ POLICY_SCOPE_USER, |
+ new base::StringValue("invalid"), |
+ NULL); |
errors.Clear(); |
EXPECT_FALSE(handler.CheckPolicySettings(policy_map, &errors)); |
EXPECT_FALSE(errors.empty()); |