| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "chrome/browser/extensions/extension_management_test_util.h" | 5 #include "chrome/browser/extensions/extension_management_test_util.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "components/crx_file/id_util.h" | 9 #include "components/crx_file/id_util.h" |
| 10 #include "components/policy/core/common/configuration_policy_provider.h" | 10 #include "components/policy/core/common/configuration_policy_provider.h" |
| 11 #include "components/policy/core/common/mock_configuration_policy_provider.h" | 11 #include "components/policy/core/common/mock_configuration_policy_provider.h" |
| 12 #include "components/policy/core/common/policy_bundle.h" | 12 #include "components/policy/core/common/policy_bundle.h" |
| 13 #include "components/policy/core/common/policy_map.h" | 13 #include "components/policy/core/common/policy_map.h" |
| 14 #include "components/policy/core/common/policy_namespace.h" | 14 #include "components/policy/core/common/policy_namespace.h" |
| 15 #include "components/policy/core/common/policy_types.h" | 15 #include "components/policy/core/common/policy_types.h" |
| 16 #include "policy/policy/policy_constants.h" | 16 #include "policy/policy_constants.h" |
| 17 | 17 |
| 18 namespace extensions { | 18 namespace extensions { |
| 19 | 19 |
| 20 namespace schema = schema_constants; | 20 namespace schema = schema_constants; |
| 21 | 21 |
| 22 namespace { | 22 namespace { |
| 23 | 23 |
| 24 const char kInstallSourcesPath[] = "*.install_sources"; | 24 const char kInstallSourcesPath[] = "*.install_sources"; |
| 25 const char kAllowedTypesPath[] = "*.allowed_types"; | 25 const char kAllowedTypesPath[] = "*.allowed_types"; |
| 26 | 26 |
| (...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 | 261 |
| 262 ExtensionManagementPolicyUpdater::~ExtensionManagementPolicyUpdater() { | 262 ExtensionManagementPolicyUpdater::~ExtensionManagementPolicyUpdater() { |
| 263 policies_->Get(policy::PolicyNamespace(policy::POLICY_DOMAIN_CHROME, | 263 policies_->Get(policy::PolicyNamespace(policy::POLICY_DOMAIN_CHROME, |
| 264 std::string())) | 264 std::string())) |
| 265 .Set(policy::key::kExtensionSettings, policy::POLICY_LEVEL_MANDATORY, | 265 .Set(policy::key::kExtensionSettings, policy::POLICY_LEVEL_MANDATORY, |
| 266 policy::POLICY_SCOPE_USER, TakePref().release(), nullptr); | 266 policy::POLICY_SCOPE_USER, TakePref().release(), nullptr); |
| 267 provider_->UpdatePolicy(policies_.Pass()); | 267 provider_->UpdatePolicy(policies_.Pass()); |
| 268 } | 268 } |
| 269 | 269 |
| 270 } // namespace extensions | 270 } // namespace extensions |
| OLD | NEW |