blob: 124050feed33e95b14f3327cd42907819c6fcf5c [file] [log] [blame]
# Copyright 2021 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_binary.gni")
import("//build/rust/rustc_test.gni")
group("tests") {
testonly = true
deps = [ ":binder_integration_test" ]
}
rustc_binary("looper_bin") {
edition = "2021"
output_name = "looper"
source_root = "src/looper.rs"
deps = [
"fidl:fuchsia.component.tests_rust",
"//src/lib/fuchsia",
"//src/lib/fuchsia-component",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:tracing",
]
sources = [ "src/looper.rs" ]
}
fuchsia_component("looper_component") {
component_name = "looper"
testonly = true
manifest = "meta/looper.cml"
deps = [ ":looper_bin" ]
}
rustc_test("binder_integration_test_bin") {
edition = "2021"
output_name = "binder_integration_test"
source_root = "src/binder_integration_test.rs"
deps = [
"fidl:fuchsia.component.tests_rust",
"//sdk/fidl/fuchsia.component:fuchsia.component_rust",
"//src/lib/fuchsia",
"//src/lib/fuchsia-component",
"//src/sys/lib/component-events",
"//third_party/rust_crates:assert_matches",
"//third_party/rust_crates:futures",
]
sources = [ "src/binder_integration_test.rs" ]
}
fuchsia_component("binder_integration_test_component") {
component_name = "binder_integration_test"
testonly = true
manifest = "meta/binder_integration_test.cml"
deps = [ ":binder_integration_test_bin" ]
}
fuchsia_test_package("binder_integration_test") {
test_components = [ ":binder_integration_test_component" ]
deps = [
":looper_component",
# https://fxbug.dev/42052321: Dep included for affected tests presubmit
"//src/sys/component_manager:component-manager-realm-builder-cmp",
]
}