# Copyright 2022 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
if (is_android) {
import("//build/config/android/rules.gni")
}
static_library("fetcher_config") {
sources = [
"fetcher_config.cc",
"fetcher_config.h",
]
deps = [
"//components/signin/public/identity_manager:identity_manager",
"//google_apis",
"//net/traffic_annotation",
]
}
static_library("mocked") {
testonly = true
sources = [
"permission_request_creator_mock.cc",
"permission_request_creator_mock.h",
]
deps = [
"//base",
"//components/supervised_user/core/browser",
"//components/supervised_user/core/common",
"//url",
]
}
static_library("fetcher") {
sources = [
"api_access_token_fetcher.cc",
"api_access_token_fetcher.h",
"kids_management_api_fetcher.cc",
"kids_management_api_fetcher.h",
"proto_fetcher.cc",
"proto_fetcher.h",
"proto_fetcher_status.cc",
"proto_fetcher_status.h",
]
deps = [
":fetcher_config",
"//base",
"//components/signin/public/identity_manager",
"//components/supervised_user/core/browser/proto",
# TODO(b/293824572): Remove when all templated code is in headers.
"//components/supervised_user/core/browser/proto:test_support",
"//components/supervised_user/core/common",
"//google_apis",
"//google_apis/common:request_util",
"//net/traffic_annotation",
"//url",
]
}
static_library("browser") {
sources = [
"child_account_service.cc",
"child_account_service.h",
"family_link_user_log_record.cc",
"family_link_user_log_record.h",
"kids_chrome_management_url_checker_client.cc",
"kids_chrome_management_url_checker_client.h",
"list_family_members_service.cc",
"list_family_members_service.h",
"permission_request_creator.h",
"permission_request_creator_impl.cc",
"permission_request_creator_impl.h",
"remote_web_approvals_manager.cc",
"remote_web_approvals_manager.h",
"supervised_user_capabilities.cc",
"supervised_user_capabilities.h",
"supervised_user_content_settings_provider.cc",
"supervised_user_content_settings_provider.h",
"supervised_user_error_page.cc",
"supervised_user_error_page.h",
"supervised_user_interstitial.cc",
"supervised_user_interstitial.h",
"supervised_user_metrics_service.cc",
"supervised_user_metrics_service.h",
"supervised_user_pref_store.cc",
"supervised_user_pref_store.h",
"supervised_user_preferences.cc",
"supervised_user_preferences.h",
"supervised_user_service.cc",
"supervised_user_service.h",
"supervised_user_service_observer.h",
"supervised_user_settings_data_type_controller.cc",
"supervised_user_settings_data_type_controller.h",
"supervised_user_settings_service.cc",
"supervised_user_settings_service.h",
"supervised_user_url_filter.cc",
"supervised_user_url_filter.h",
"supervised_user_utils.cc",
"supervised_user_utils.h",
"web_content_handler.cc",
"web_content_handler.h",
]
public_deps = [
"//components/autofill/core/common",
"//components/history/core/common",
"//components/keyed_service/core",
"//components/policy/core/common:common_constants",
"//components/pref_registry",
"//components/safe_search_api",
"//components/safe_search_api:safe_search_client",
"//components/supervised_user/core/browser/proto",
"//extensions/buildflags",
"//third_party/protobuf:protobuf_lite",
]
deps = [
":fetcher",
":fetcher_config",
"//base",
"//components/content_settings/core/browser",
"//components/feed/core/shared_prefs:feed_shared_prefs",
"//components/google/core/common",
"//components/prefs",
"//components/resources:components_resources",
"//components/signin/internal/identity_manager",
"//components/signin/public/base",
"//components/signin/public/identity_manager",
"//components/strings:components_strings_grit",
"//components/supervised_user/core/common",
"//components/sync",
"//components/url_matcher:url_matcher",
"//components/user_manager:user_manager",
"//google_apis",
"//net",
"//services/network/public/cpp",
"//services/network/public/mojom",
"//ui/base",
"//url",
]
}
if (is_android) {
java_cpp_enum("supervised_user_utils_enum_javagen") {
sources = [ "supervised_user_utils.h" ]
}
}
source_set("unit_tests") {
testonly = true
sources = [
"api_access_token_fetcher_unittest.cc",
"child_account_service_unittest.cc",
"family_link_user_log_record_unittest.cc",
"fetcher_config_unittest.cc",
"kids_chrome_management_url_checker_client_unittest.cc",
"list_family_members_service_unittest.cc",
"proto_fetcher_status_unittest.cc",
"proto_fetcher_unittest.cc",
"remote_web_approvals_manager_unittest.cc",
"supervised_user_capabilities_unittest.cc",
"supervised_user_content_settings_provider_unittest.cc",
"supervised_user_error_page_unittest.cc",
"supervised_user_metrics_service_unittest.cc",
"supervised_user_pref_store_unittest.cc",
"supervised_user_preferences_unittest.cc",
"supervised_user_service_unittest.cc",
"supervised_user_settings_data_type_controller_unittest.cc",
"supervised_user_settings_service_unittest.cc",
"supervised_user_url_filter_unittest.cc",
"supervised_user_utils_unittest.cc",
]
deps = [
":browser",
":fetcher",
":fetcher_config",
"//base",
"//base/test:test_support",
"//components/content_settings/core/browser:test_support",
"//components/prefs:test_support",
"//components/resources:components_resources",
"//components/safe_search_api:test_support",
"//components/signin/public/base",
"//components/signin/public/base:test_support",
"//components/signin/public/identity_manager",
"//components/signin/public/identity_manager:test_support",
"//components/strings:components_strings_grit",
"//components/supervised_user/core/browser/proto",
"//components/supervised_user/core/browser/proto:test_support",
"//components/supervised_user/core/common",
"//components/supervised_user/test_support",
"//components/sync:test_support",
"//components/sync_preferences:test_support",
"//google_apis/common:test_support",
"//services/network:test_support",
"//testing/gmock",
"//testing/gtest",
"//ui/base",
]
}