# Copyright 2015 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/config/chromeos/ui_mode.gni")
component("proxy_config") {
sources = [
"pref_proxy_config_tracker.cc",
"pref_proxy_config_tracker.h",
"pref_proxy_config_tracker_impl.cc",
"pref_proxy_config_tracker_impl.h",
"proxy_config_dictionary.cc",
"proxy_config_dictionary.h",
"proxy_config_export.h",
"proxy_config_pref_names.h",
"proxy_prefs.cc",
"proxy_prefs.h",
]
defines = [ "PROXY_CONFIG_IMPLEMENTATION" ]
deps = [
"//base",
"//components/policy:generated",
"//components/policy/core/browser",
"//components/policy/core/common",
"//components/prefs",
"//components/strings",
"//net",
"//url",
]
# TODO(crbug.com/40446749): Break a header include cycle on ChromeOS
# and disable include checking so GN doesn't complain about the missing
# dependency (it still links OK). This cycle should be fixed and header
# checking enabled.
if (is_chromeos_ash) {
check_includes = false
} else {
deps += [ "//components/pref_registry" ]
}
if (!is_ios) {
sources += [
"proxy_policy_handler.cc",
"proxy_policy_handler.h",
]
}
}
source_set("unit_tests") {
testonly = true
sources = [
"pref_proxy_config_tracker_impl_unittest.cc",
"proxy_config_dictionary_unittest.cc",
"proxy_prefs_unittest.cc",
]
deps = [
":proxy_config",
"//base",
"//base/test:test_support",
"//components/policy:generated",
"//components/policy/core/browser",
"//components/policy/core/browser:test_support",
"//components/policy/core/common",
"//components/prefs:test_support",
"//net",
"//net:test_support",
"//testing/gmock",
"//testing/gtest",
"//third_party/abseil-cpp:absl",
]
if (!is_ios) {
sources += [ "proxy_policy_handler_unittest.cc" ]
}
}