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

Unified Diff: components/policy/core/common/policy_loader_ios_unittest.mm

Issue 1304843004: Add source column to chrome://policy showing the origins of policies. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed another test. Created 5 years, 3 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_loader_ios_unittest.mm
diff --git a/components/policy/core/common/policy_loader_ios_unittest.mm b/components/policy/core/common/policy_loader_ios_unittest.mm
index f22d37f41caecb97a91e8b43290d0a474fa7175b..dba3991a800a217d809e1c836a554ab108eaf415 100644
--- a/components/policy/core/common/policy_loader_ios_unittest.mm
+++ b/components/policy/core/common/policy_loader_ios_unittest.mm
@@ -16,6 +16,7 @@
#include "components/policy/core/common/policy_loader_ios.h"
#include "components/policy/core/common/policy_map.h"
#include "components/policy/core/common/policy_test_utils.h"
+#include "components/policy/core/common/policy_types.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace policy {
@@ -68,7 +69,8 @@ class TestHarness : public PolicyProviderTestHarness {
};
TestHarness::TestHarness(bool use_encoded_key)
- : PolicyProviderTestHarness(POLICY_LEVEL_MANDATORY, POLICY_SCOPE_MACHINE),
+ : PolicyProviderTestHarness(POLICY_LEVEL_MANDATORY, POLICY_SCOPE_MACHINE,
+ POLICY_SOURCE_PLATFORM),
use_encoded_key_(use_encoded_key) {}
TestHarness::~TestHarness() {
@@ -251,9 +253,11 @@ TEST(PolicyProviderIOSTest, ChromePolicyOverEncodedChromePolicy) {
PolicyMap& expectedMap =
expected.Get(PolicyNamespace(POLICY_DOMAIN_CHROME, ""));
expectedMap.Set("shared", POLICY_LEVEL_MANDATORY, POLICY_SCOPE_MACHINE,
- new base::StringValue("right"), NULL);
+ POLICY_SOURCE_PLATFORM, new base::StringValue("right"),
+ nullptr);
expectedMap.Set("key2", POLICY_LEVEL_MANDATORY, POLICY_SCOPE_MACHINE,
- new base::StringValue("value2"), NULL);
+ POLICY_SOURCE_PLATFORM, new base::StringValue("value2"),
+ nullptr);
scoped_refptr<base::TestSimpleTaskRunner> taskRunner =
new base::TestSimpleTaskRunner();
« no previous file with comments | « components/policy/core/common/policy_loader_ios.mm ('k') | components/policy/core/common/policy_loader_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698