1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109
|
# Copyright 2021 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, "Quick Pair protocols (e.g. Fast Pair) are ash-chrome only")
component("common") {
output_name = "quick_pair_common"
defines = [ "IS_QUICK_PAIR_COMMON_IMPL" ]
sources = [
"account_key_failure.cc",
"account_key_failure.h",
"constants.cc",
"constants.h",
"device.cc",
"device.h",
"fast_pair/fast_pair_decoder.cc",
"fast_pair/fast_pair_decoder.h",
"fast_pair/fast_pair_feature_usage_metrics_logger.cc",
"fast_pair/fast_pair_feature_usage_metrics_logger.h",
"fast_pair/fast_pair_http_result.cc",
"fast_pair/fast_pair_http_result.h",
"fast_pair/fast_pair_metrics.cc",
"fast_pair/fast_pair_metrics.h",
"log_buffer.cc",
"log_buffer.h",
"logging.cc",
"logging.h",
"pair_failure.cc",
"pair_failure.h",
"protocol.cc",
"protocol.h",
"quick_pair_browser_delegate.cc",
"quick_pair_browser_delegate.h",
]
deps = [
"//ash/constants:constants",
"//ash/quick_pair/proto:fastpair_proto",
"//base",
"//chromeos/ash/components/feature_usage",
"//chromeos/ash/services/quick_pair/public/mojom",
"//components/cross_device/logging:logging",
"//components/metrics/structured:structured_events",
"//components/metrics/structured:structured_metrics_features",
"//components/prefs",
"//device/bluetooth",
"//device/bluetooth/public/cpp",
"//net",
"//services/network/public/cpp",
"//services/network/public/mojom",
"//url",
]
}
static_library("test_support") {
testonly = true
sources = [
"fake_bluetooth_adapter.cc",
"fake_bluetooth_adapter.h",
"fake_quick_pair_browser_delegate.cc",
"fake_quick_pair_browser_delegate.h",
"fast_pair/fast_pair_service_data_creator.cc",
"fast_pair/fast_pair_service_data_creator.h",
"mock_quick_pair_browser_delegate.cc",
"mock_quick_pair_browser_delegate.h",
]
deps = [
":common",
"//ash",
"//ash/constants",
"//ash/quick_pair/repository",
"//base/test:test_support",
"//chromeos/ash/services/quick_pair/public/mojom",
"//components/image_fetcher/core",
"//components/prefs:test_support",
"//device/bluetooth:mocks",
"//services/network/public/cpp",
"//testing/gtest",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"device_unittest.cc",
"fast_pair/fast_pair_decoder_unittest.cc",
"fast_pair/fast_pair_feature_usage_metrics_logger_unittest.cc",
"log_buffer_unittest.cc",
"logging_unittest.cc",
]
deps = [
":common",
":test_support",
"//ash/constants:constants",
"//base/test:test_support",
"//chromeos/ash/components/feature_usage",
"//components/prefs:test_support",
"//device/bluetooth",
"//device/bluetooth:mocks",
"//testing/gtest",
]
}
|