chromium/chrome/browser/nearby_sharing/local_device_data/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("local_device_data") {
  sources = [
    "nearby_share_device_data_updater.cc",
    "nearby_share_device_data_updater.h",
    "nearby_share_device_data_updater_impl.cc",
    "nearby_share_device_data_updater_impl.h",
    "nearby_share_local_device_data_manager.cc",
    "nearby_share_local_device_data_manager.h",
    "nearby_share_local_device_data_manager_impl.cc",
    "nearby_share_local_device_data_manager_impl.h",
  ]

  public_deps = [ "//chromeos/ash/services/nearby/public/mojom" ]

  deps = [
    "//base",
    "//chrome/app:generated_resources",
    "//chrome/app:generated_resources_grit",
    "//chrome/browser/nearby_sharing/client",
    "//chrome/browser/nearby_sharing/common",
    "//chromeos/ash/components/nearby/common/client",
    "//chromeos/ash/components/nearby/common/scheduling",
    "//components/cross_device/logging:logging",
    "//components/prefs",
    "//third_party/nearby:device_rpc_proto",
    "//third_party/nearby:rpc_resources_proto",
    "//ui/base",
    "//ui/chromeos",
  ]
}

source_set("test_support") {
  testonly = true

  sources = [
    "fake_nearby_share_device_data_updater.cc",
    "fake_nearby_share_device_data_updater.h",
    "fake_nearby_share_local_device_data_manager.cc",
    "fake_nearby_share_local_device_data_manager.h",
  ]

  deps = [
    ":local_device_data",
    "//base",
    "//third_party/nearby:device_rpc_proto",
    "//third_party/nearby:rpc_resources_proto",
  ]
}

source_set("unit_tests") {
  testonly = true

  sources = [
    "nearby_share_device_data_updater_impl_unittest.cc",
    "nearby_share_local_device_data_manager_impl_unittest.cc",
  ]

  deps = [
    ":local_device_data",
    ":test_support",
    "//base",
    "//base/test:test_support",
    "//chrome/app:generated_resources",
    "//chrome/app:generated_resources_grit",
    "//chrome/browser/nearby_sharing/client",
    "//chrome/browser/nearby_sharing/client:test_support",
    "//chrome/browser/nearby_sharing/common",
    "//chrome/browser/nearby_sharing/common:test_support",
    "//chromeos/ash/components/nearby/common/client",
    "//chromeos/ash/components/nearby/common/scheduling",
    "//chromeos/ash/components/nearby/common/scheduling:test_support",
    "//components/sync_preferences:test_support",
    "//testing/gtest",
    "//third_party/nearby:device_rpc_proto",
    "//third_party/nearby:rpc_resources_proto",
    "//ui/base",
    "//ui/chromeos",
  ]
}