blob: d1a64ad4c2d642402e6d7746b5d04ed3eeac05bd [file] [log] [blame]
# Copyright 2018 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/components.gni")
import("//build/rust/rustc_library.gni")
rustc_library("fuchsia-bluetooth") {
with_unit_tests = true
# TODO(armansito): Split out testing code into a separate library and move
# test-specific dependencies out.
deps = [
"//sdk/fidl/fuchsia.bluetooth:fuchsia.bluetooth-rustc",
"//sdk/fidl/fuchsia.bluetooth.bredr:fuchsia.bluetooth.bredr-rustc",
"//sdk/fidl/fuchsia.bluetooth.le:fuchsia.bluetooth.le-rustc",
"//sdk/fidl/fuchsia.bluetooth.sys:fuchsia.bluetooth.sys-rustc",
"//sdk/fidl/fuchsia.hardware.audio:fuchsia.hardware.audio-rustc",
"//sdk/fidl/fuchsia.hardware.bluetooth:fuchsia.hardware.bluetooth-rustc",
"//src/lib/diagnostics/inspect/contrib/rust",
"//src/lib/diagnostics/inspect/derive",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fidl_table_validation",
"//src/lib/fuchsia-async",
"//src/lib/zircon/rust:fuchsia-zircon",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:byteorder",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:lazy_static",
"//third_party/rust_crates:log",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:pretty",
"//third_party/rust_crates:proptest",
"//third_party/rust_crates:rand",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:slab",
"//third_party/rust_crates:thiserror",
"//third_party/rust_crates:uuid",
]
test_deps = [ "//third_party/rust_crates:assert_matches" ]
sources = [
"src/assigned_numbers.rs",
"src/assigned_numbers/constants.rs",
"src/constants.rs",
"src/detachable_map.rs",
"src/error.rs",
"src/expectation.rs",
"src/expectation/asynchronous.rs",
"src/expectation/host_driver.rs",
"src/expectation/peer.rs",
"src/expectation/prelude.rs",
"src/expectation/test.rs",
"src/host.rs",
"src/inspect.rs",
"src/lib.rs",
"src/profile.rs",
"src/types.rs",
"src/types/address.rs",
"src/types/bonding_data.rs",
"src/types/channel.rs",
"src/types/host_info.rs",
"src/types/id.rs",
"src/types/io_capabilities.rs",
"src/types/le.rs",
"src/types/pairing_options.rs",
"src/types/peer.rs",
"src/types/uuid.rs",
"src/util.rs",
]
configs -= [ "//build/config/rust:allow_unused_results" ]
}
fuchsia_unittest_package("bluetooth-crate-tests") {
deps = [ ":fuchsia-bluetooth_test" ]
}
group("tests") {
testonly = true
deps = [ ":bluetooth-crate-tests" ]
}