chromium/components/policy/content/BUILD.gn

# Copyright 2017 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/features.gni")

assert(use_blink,
       "Policy Throttle should not be referenced on non-blink platforms")

source_set("safe_sites_navigation_throttle") {
  sources = [
    "safe_search_service.cc",
    "safe_search_service.h",
    "safe_sites_navigation_throttle.cc",
    "safe_sites_navigation_throttle.h",
  ]

  deps = [
    "//base",
    "//components/keyed_service/content:content",
    "//components/policy/core/browser",
    "//components/safe_search_api",
    "//components/safe_search_api:safe_search_client",
    "//components/url_matcher",
    "//content/public/browser",
    "//net",
  ]
}

source_set("content") {
  sources = [
    "policy_blocklist_navigation_throttle.cc",
    "policy_blocklist_navigation_throttle.h",
    "policy_blocklist_service.cc",
    "policy_blocklist_service.h",
  ]

  deps = [
    ":safe_sites_navigation_throttle",
    "//components/keyed_service/content:content",
    "//components/policy/core/browser",
    "//components/prefs",
    "//components/user_prefs:user_prefs",
    "//content/public/browser",
  ]
}

source_set("unit_tests") {
  testonly = true
  sources = [ "policy_blocklist_navigation_throttle_unittest.cc" ]
  deps = [
    ":content",
    ":safe_sites_navigation_throttle",
    "//base",
    "//components/keyed_service/content",
    "//components/policy/core/browser",
    "//components/safe_search_api",
    "//components/safe_search_api:safe_search_client",
    "//components/safe_search_api:test_support",
    "//components/sync_preferences:test_support",
    "//components/user_prefs:user_prefs",
    "//content/public/browser",
    "//content/test:test_support",
    "//testing/gtest",
    "//url",
  ]
}