OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include <CoreFoundation/CoreFoundation.h> | 5 #include <CoreFoundation/CoreFoundation.h> |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/files/file_path.h" | 9 #include "base/files/file_path.h" |
10 #include "base/mac/scoped_cftyperef.h" | 10 #include "base/mac/scoped_cftyperef.h" |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 prefs_->AddTestItem(name, test_value.get(), false); | 185 prefs_->AddTestItem(name, test_value.get(), false); |
186 | 186 |
187 // Make the provider read the updated |prefs_|. | 187 // Make the provider read the updated |prefs_|. |
188 provider_->RefreshPolicies(); | 188 provider_->RefreshPolicies(); |
189 loop_.RunUntilIdle(); | 189 loop_.RunUntilIdle(); |
190 PolicyBundle expected_bundle; | 190 PolicyBundle expected_bundle; |
191 expected_bundle.Get(PolicyNamespace(POLICY_DOMAIN_CHROME, std::string())) | 191 expected_bundle.Get(PolicyNamespace(POLICY_DOMAIN_CHROME, std::string())) |
192 .Set(test_keys::kKeyString, | 192 .Set(test_keys::kKeyString, |
193 POLICY_LEVEL_RECOMMENDED, | 193 POLICY_LEVEL_RECOMMENDED, |
194 POLICY_SCOPE_USER, | 194 POLICY_SCOPE_USER, |
195 base::Value::CreateStringValue("string value"), | 195 new base::StringValue("string value"), |
196 NULL); | 196 NULL); |
197 EXPECT_TRUE(provider_->policies().Equals(expected_bundle)); | 197 EXPECT_TRUE(provider_->policies().Equals(expected_bundle)); |
198 } | 198 } |
199 | 199 |
200 } // namespace policy | 200 } // namespace policy |
OLD | NEW |