chromium/chrome/browser/nearby_sharing/client/BUILD.gn

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

assert(is_chromeos, "Nearby Share is CrOS only")

source_set("client") {
  sources = [
    "nearby_share_client.h",
    "nearby_share_client_impl.cc",
    "nearby_share_client_impl.h",
    "nearby_share_http_notifier.cc",
    "nearby_share_http_notifier.h",
  ]

  deps = [
    "//base",
    "//chrome/browser/nearby_sharing/common",
    "//chromeos/ash/components/nearby/common/client",
    "//components/cross_device/logging:logging",
    "//components/signin/public/identity_manager",
    "//net",
    "//net/traffic_annotation",
    "//services/network/public/cpp",
    "//services/network/public/mojom",
    "//third_party/nearby:certificate_rpc_proto",
    "//third_party/nearby:contact_rpc_proto",
    "//third_party/nearby:device_rpc_proto",
    "//third_party/nearby:rpc_resources_proto",
    "//url",
  ]
}

source_set("test_support") {
  testonly = true

  sources = [
    "fake_nearby_share_client.cc",
    "fake_nearby_share_client.h",
  ]

  deps = [
    ":client",
    "//base",
    "//chrome/browser/nearby_sharing/common",
    "//chromeos/ash/components/nearby/common/client",
    "//third_party/nearby:certificate_rpc_proto",
    "//third_party/nearby:contact_rpc_proto",
    "//third_party/nearby:device_rpc_proto",
  ]
}

source_set("unit_tests") {
  testonly = true

  sources = [ "nearby_share_client_impl_unittest.cc" ]

  deps = [
    ":client",
    "//base",
    "//base/test:test_support",
    "//chrome/browser/nearby_sharing/common",
    "//chromeos/ash/components/nearby/common/client",
    "//components/signin/public/identity_manager:test_support",
    "//net",
    "//net/traffic_annotation:test_support",
    "//services/network:test_support",
    "//testing/gtest",
    "//third_party/nearby:certificate_rpc_proto",
    "//third_party/nearby:contact_rpc_proto",
    "//third_party/nearby:device_rpc_proto",
    "//third_party/nearby:rpc_resources_proto",
  ]
}