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

Unified Diff: chrome/browser/chromeos/policy/device_local_account_policy_service_unittest.cc

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: chrome/browser/chromeos/policy/device_local_account_policy_service_unittest.cc
diff --git a/chrome/browser/chromeos/policy/device_local_account_policy_service_unittest.cc b/chrome/browser/chromeos/policy/device_local_account_policy_service_unittest.cc
index 53649bf65acb0984c0828ce3106727fd38a3bad2..ae89764291a7fe0556c134caa64abca0d0905e37 100644
--- a/chrome/browser/chromeos/policy/device_local_account_policy_service_unittest.cc
+++ b/chrome/browser/chromeos/policy/device_local_account_policy_service_unittest.cc
@@ -38,6 +38,7 @@
#include "components/policy/core/common/mock_configuration_policy_provider.h"
#include "components/policy/core/common/policy_bundle.h"
#include "components/policy/core/common/policy_map.h"
+#include "components/policy/core/common/policy_types.h"
#include "components/policy/core/common/schema_registry.h"
#include "net/url_request/url_request_context_getter.h"
#include "net/url_request/url_request_test_util.h"
@@ -143,6 +144,7 @@ void DeviceLocalAccountPolicyServiceTestBase::SetUp() {
expected_policy_map_.Set(key::kDisableSpdy,
POLICY_LEVEL_MANDATORY,
POLICY_SCOPE_USER,
+ POLICY_SOURCE_CLOUD,
new base::FundamentalValue(true),
NULL);
@@ -806,6 +808,7 @@ void DeviceLocalAccountPolicyProviderTest::SetUp() {
expected_policy_map_.Set(key::kLidCloseAction,
POLICY_LEVEL_MANDATORY,
POLICY_SCOPE_MACHINE,
+ POLICY_SOURCE_ENTERPRISE_OVERRIDE,
new base::FundamentalValue(
chromeos::PowerPolicyController::
ACTION_STOP_SESSION),
@@ -813,16 +816,19 @@ void DeviceLocalAccountPolicyProviderTest::SetUp() {
expected_policy_map_.Set(key::kShelfAutoHideBehavior,
POLICY_LEVEL_MANDATORY,
POLICY_SCOPE_MACHINE,
+ POLICY_SOURCE_ENTERPRISE_OVERRIDE,
new base::StringValue("Never"),
NULL);
expected_policy_map_.Set(key::kShowLogoutButtonInTray,
POLICY_LEVEL_MANDATORY,
POLICY_SCOPE_MACHINE,
+ POLICY_SOURCE_ENTERPRISE_OVERRIDE,
new base::FundamentalValue(true),
NULL);
expected_policy_map_.Set(key::kFullscreenAllowed,
POLICY_LEVEL_MANDATORY,
POLICY_SCOPE_MACHINE,
+ POLICY_SOURCE_ENTERPRISE_OVERRIDE,
new base::FundamentalValue(false),
NULL);
}
@@ -889,6 +895,7 @@ TEST_F(DeviceLocalAccountPolicyProviderTest, Policy) {
.Set(key::kDisableSpdy,
POLICY_LEVEL_MANDATORY,
POLICY_SCOPE_USER,
+ POLICY_SOURCE_CLOUD,
new base::FundamentalValue(false),
NULL);
EXPECT_TRUE(expected_policy_bundle.Equals(provider_->policies()));

Powered by Google App Engine
This is Rietveld 408576698