| # 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") |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":unittests-pkg" ] |
| } |
| |
| rustc_binary("bin") { |
| name = "fuzz_manager" |
| visibility = [ ":*" ] |
| edition = "2021" |
| deps = [ |
| "//sdk/fidl/fuchsia.diagnostics:fuchsia.diagnostics_rust", |
| "//sdk/fidl/fuchsia.test.manager:fuchsia.test.manager_rust", |
| "//src/lib/fidl/rust/fidl", |
| "//src/lib/fuchsia", |
| "//src/lib/fuchsia-async", |
| "//src/lib/fuchsia-component", |
| "//src/lib/zircon/rust:fuchsia-zircon", |
| "//src/sys/fuzzing/fidl:fuchsia.fuzzer_rust", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:async-trait", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:tracing", |
| "//third_party/rust_crates:url", |
| ] |
| sources = [ |
| "src/diagnostics.rs", |
| "src/events.rs", |
| "src/fuzzer.rs", |
| "src/main.rs", |
| "src/manager.rs", |
| "src/test_support.rs", |
| ] |
| with_unit_tests = true |
| test_deps = [ "//sdk/fidl/fuchsia.mem:fuchsia.mem_rust" ] |
| } |
| |
| fuchsia_component("manager") { |
| component_name = "fuzz-manager" |
| visibility = [ ":*" ] |
| testonly = true |
| manifest = "meta/fuzz-manager.cml" |
| deps = [ ":bin" ] |
| } |
| |
| fuchsia_component("unittests") { |
| visibility = [ ":*" ] |
| testonly = true |
| manifest = "meta/unittests.cml" |
| deps = [ ":bin_test" ] |
| } |
| |
| fuchsia_test_package("unittests-pkg") { |
| package_name = "fuzz-manager-unittests" |
| test_components = [ ":unittests" ] |
| } |