| # Copyright 2024 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") |
| |
| rustc_test("dictionaries_integration_test_bin") { |
| edition = "2024" |
| testonly = true |
| sources = [ "src/lib.rs" ] |
| deps = [ |
| "//examples/components/routing/fidl:echo_rust", |
| "//sdk/fidl/fuchsia.component:fuchsia.component_rust", |
| "//sdk/fidl/fuchsia.component.decl:fuchsia.component.decl_rust", |
| "//sdk/fidl/fuchsia.io:fuchsia.io_rust", |
| "//src/lib/fidl/rust/fidl", |
| "//src/lib/fuchsia", |
| "//src/lib/fuchsia-async", |
| "//src/lib/fuchsia-component", |
| "//src/lib/fuchsia-component-test", |
| "//src/lib/fuchsia-fs", |
| "//src/lib/fuchsia-sync", |
| "//src/storage/lib/vfs/rust:vfs", |
| "//src/sys/component_manager/tests/fidl:components_rust", |
| "//src/sys/lib/cm_rust", |
| "//src/sys/lib/cm_types", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:log", |
| ] |
| } |
| |
| rustc_binary("dict_trigger_bin") { |
| testonly = true |
| name = "dict_trigger" |
| edition = "2024" |
| deps = [ |
| "//examples/components/routing/fidl:echo_rust", |
| "//sdk/fidl/fuchsia.component.runtime:fuchsia.component.runtime_rust", |
| "//src/lib/fidl/rust/fidl", |
| "//src/lib/fuchsia-async", |
| "//src/lib/fuchsia-component", |
| "//src/storage/lib/vfs/rust:vfs", |
| "//src/sys/component_manager/tests/fidl:components_rust", |
| "//third_party/rust_crates:futures", |
| "//third_party/rust_crates:log", |
| ] |
| source_root = "src/trigger.rs" |
| sources = [ "src/trigger.rs" ] |
| } |
| |
| fuchsia_unittest_package("dictionaries_integration_test") { |
| manifest = "meta/dictionaries_integration_test.cml" |
| restricted_features = [ "use_dictionaries" ] |
| deps = [ |
| ":dictionaries_integration_test_bin", |
| ":directory_test", |
| ":trigger_c", |
| "//src/sys/component_manager:component-manager-realm-builder-cmp", |
| "//src/sys/component_manager/testing/echo_server", |
| "//src/sys/component_manager/tests/collections:trigger_a", |
| "//src/sys/component_manager/tests/collections:trigger_b", |
| ] |
| } |
| |
| fuchsia_component("trigger_c") { |
| testonly = true |
| deps = [ ":dict_trigger_bin" ] |
| manifest = "meta/trigger_c.cml" |
| restricted_features = [ "dynamic_dictionaries" ] |
| } |
| |
| fuchsia_component("directory_test") { |
| testonly = true |
| manifest = "meta/directory_test.cml" |
| deps = [ ":dict_trigger_bin" ] |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":dictionaries_integration_test" ] |
| } |