chromium/components/proxy_config/proxy_policy_handler_unittest.cc

// Copyright 2013 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "components/proxy_config/proxy_policy_handler.h"

#include <memory>
#include <optional>
#include <string>

#include "base/memory/ptr_util.h"
#include "base/values.h"
#include "components/policy/core/browser/configuration_policy_pref_store.h"
#include "components/policy/core/browser/configuration_policy_pref_store_test.h"
#include "components/policy/core/common/policy_service_impl.h"
#include "components/policy/core/common/policy_types.h"
#include "components/policy/core/common/proxy_settings_constants.h"
#include "components/policy/policy_constants.h"
#include "components/proxy_config/proxy_config_dictionary.h"
#include "components/proxy_config/proxy_config_pref_names.h"
#include "testing/gtest/include/gtest/gtest.h"

ConfigurationPolicyHandler;
ConfigurationPolicyPrefStore;
ConfigurationPolicyPrefStoreTest;
kProxyPacMandatory;
POLICY_LEVEL_MANDATORY;
POLICY_LEVEL_RECOMMENDED;
POLICY_SCOPE_USER;
POLICY_SOURCE_CLOUD;
PolicyMap;
PolicyServiceImpl;
kProxyBypassList;
kProxyMode;
kProxyPacUrl;
kProxyServer;
kProxyServerMode;
kProxySettings;

namespace proxy_config {

// Test cases for the proxy policy settings.
class ProxyPolicyHandlerTest : public ConfigurationPolicyPrefStoreTest {};

TEST_F(ProxyPolicyHandlerTest, ManualOptions) {}

TEST_F(ProxyPolicyHandlerTest, ManualOptionsReversedApplyOrder) {}

TEST_F(ProxyPolicyHandlerTest, ManualOptionsInvalid) {}

TEST_F(ProxyPolicyHandlerTest, NoProxyServerMode) {}

TEST_F(ProxyPolicyHandlerTest, NoProxyModeName) {}

TEST_F(ProxyPolicyHandlerTest, AutoDetectProxyServerMode) {}

TEST_F(ProxyPolicyHandlerTest, AutoDetectProxyModeName) {}

TEST_F(ProxyPolicyHandlerTest, PacScriptProxyMode) {}

// ProxyPacMandatory can be set only via ProxySettings.
TEST_F(ProxyPolicyHandlerTest, PacScriptProxyModeWithPacMandatory) {}

TEST_F(ProxyPolicyHandlerTest, PacScriptProxyModeInvalid) {}

// Regression test for http://crbug.com/78016, device management server returns
// empty strings for unset properties.
TEST_F(ProxyPolicyHandlerTest, PacScriptProxyModeBug78016) {}

TEST_F(ProxyPolicyHandlerTest, UseSystemProxyServerMode) {}

TEST_F(ProxyPolicyHandlerTest, UseSystemProxyMode) {}

TEST_F(ProxyPolicyHandlerTest, ProxyModeOverridesProxyServerMode) {}

TEST_F(ProxyPolicyHandlerTest, ProxyInvalid) {}

TEST_F(ProxyPolicyHandlerTest, SeparateProxyPoliciesMerging) {}

}  // namespace proxy_config