blob: a063b8ee145593a119e5f99c3611c396fb4c4918 [file] [log] [blame]
# Copyright 2019 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/dist/renamed_binary.gni")
import("//build/rust/rustc_library.gni")
import("//build/rust/rustc_test.gni")
rustc_library("lib") {
name = "lib"
edition = "2018"
deps = [
"//garnet/lib/rust/io_util",
"//sdk/fidl/fuchsia.boot:fuchsia.boot-rustc",
"//sdk/fidl/fuchsia.cobalt:fuchsia.cobalt-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.logger:fuchsia.logger-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/hierarchy/rust",
"//src/lib/diagnostics/reader/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/http-uri-ext",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/lib/metrics:cobalt_sw_delivery_registry_rustlib",
"//src/sys/pkg/testing/blobfs-ramdisk",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/cobalt/src/lib/client/rust:cobalt-client",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:http",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [
"src/lib.rs",
"src/mock_filesystem.rs",
]
}
rustc_test("dynamic_repositories_disabled") {
name = "dynamic-repositories-disabled"
edition = "2018"
source_root = "src/dynamic_repositories_disabled.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/dynamic_repositories_disabled.rs" ]
}
rustc_test("dynamic_rewrite_disabled") {
name = "dynamic-rewrite-disabled"
edition = "2018"
source_root = "src/dynamic_rewrite_disabled.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/dynamic_rewrite_disabled.rs" ]
}
rustc_test("pkg_resolve_inspect") {
name = "pkg-resolve-inspect"
edition = "2018"
source_root = "src/pkg_resolve_inspect.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/pkg_resolve_inspect.rs" ]
}
rustc_test("resolve_fails") {
name = "resolve-fails"
edition = "2018"
source_root = "src/resolve_fails.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//src/lib/fuchsia-async",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/lib/metrics:cobalt_sw_delivery_registry_rustlib",
]
sources = [ "src/resolve_fails.rs" ]
}
rustc_test("resolve_propagates_pkgfs_failure") {
name = "resolve-propagates-pkgfs-failure"
edition = "2018"
source_root = "src/resolve_propagates_pkgfs_failure.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/storage/pseudo-fs",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/resolve_propagates_pkgfs_failure.rs" ]
}
rustc_test("resolve_recovers_from_http_errors") {
name = "resolve-recovers-from-http-errors"
edition = "2018"
source_root = "src/resolve_recovers_from_http_errors.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/resolve_recovers_from_http_errors.rs" ]
}
rustc_test("resolve_resumes_blob_gets") {
name = "resolve-resumes-blob-gets"
edition = "2018"
source_root = "src/resolve_resumes_blob_gets.rs"
deps = [
":lib",
"//src/lib/fuchsia-async",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/lib/metrics:cobalt_sw_delivery_registry_rustlib",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:http",
"//third_party/rust_crates:hyper",
]
sources = [ "src/resolve_resumes_blob_gets.rs" ]
}
rustc_test("resolve_succeeds_with_broken_minfs") {
name = "resolve-succeeds-with-broken-minfs"
edition = "2018"
source_root = "src/resolve_succeeds_with_broken_minfs.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/resolve_succeeds_with_broken_minfs.rs" ]
}
rustc_test("resolve_succeeds") {
name = "resolve-succeeds"
edition = "2018"
source_root = "src/resolve_succeeds.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/http-uri-ext",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:http",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:rand",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/resolve_succeeds.rs" ]
}
rustc_test("get_hash") {
name = "get-hash"
edition = "2018"
source_root = "src/get_hash.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.inspect:fuchsia.inspect-rustc",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.net:fuchsia.net-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//sdk/fidl/fuchsia.posix.socket:fuchsia.posix.socket-rustc",
"//sdk/fidl/fuchsia.sys:fuchsia.sys-rustc",
"//sdk/fidl/fuchsia.tracing.provider:fuchsia.tracing.provider-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-hyper",
"//src/lib/fuchsia-url",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-ext",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:glob",
"//third_party/rust_crates:hex",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:parking_lot",
"//third_party/rust_crates:serde",
"//third_party/rust_crates:serde_json",
"//third_party/rust_crates:tempfile",
"//third_party/rust_crates:void",
]
sources = [ "src/get_hash.rs" ]
}
rustc_test("system_cache_fallback") {
name = "system-cache-fallback"
edition = "2018"
source_root = "src/system_cache_fallback.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//src/lib/diagnostics/inspect/rust",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-hash",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/blobfs-ramdisk",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:rand",
"//third_party/rust_crates:serde_json",
]
sources = [ "src/system_cache_fallback.rs" ]
}
rustc_test("base_pinning") {
name = "base-pinning"
edition = "2018"
source_root = "src/base_pinning.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.io:fuchsia.io-rustc",
"//sdk/fidl/fuchsia.pkg.rewrite:fuchsia.pkg.rewrite-rustc",
"//src/lib/fdio/rust:fdio",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/lib/fidl-fuchsia-pkg-rewrite-ext",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/testing/pkgfs-ramdisk",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:openat",
"//third_party/rust_crates:serde_json",
]
sources = [ "src/base_pinning.rs" ]
}
rustc_test("metrics") {
name = "metrics"
edition = "2018"
source_root = "src/metrics.rs"
deps = [
":lib",
"//sdk/fidl/fuchsia.cobalt:fuchsia.cobalt-rustc",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg-rustc",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-async",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/lib/fuchsia-pkg-testing",
"//src/sys/pkg/lib/metrics:cobalt_sw_delivery_registry_rustlib",
"//third_party/cobalt/src/lib/client/rust:cobalt-client",
"//third_party/rust_crates:hyper",
"//third_party/rust_crates:matches",
"//third_party/rust_crates:serde_json",
]
sources = [ "src/metrics.rs" ]
}
fuchsia_test_component("dynamic_repositories_disabled-component") {
component_name = "dynamic-repositories-disabled"
manifest = "meta/dynamic-repositories-disabled.cmx"
deps = [ ":dynamic_repositories_disabled" ]
}
fuchsia_test_component("dynamic_rewrite_disabled-component") {
component_name = "dynamic-rewrite-disabled"
manifest = "meta/dynamic-rewrite-disabled.cmx"
deps = [ ":dynamic_rewrite_disabled" ]
}
fuchsia_test_component("get_hash-component") {
component_name = "get-hash"
manifest = "meta/get-hash.cmx"
deps = [ ":get_hash" ]
}
fuchsia_test_component("pkg_resolve_inspect-component") {
component_name = "pkg-resolve-inspect"
manifest = "meta/pkg-resolve-inspect.cmx"
deps = [ ":pkg_resolve_inspect" ]
}
fuchsia_test_component("resolve_propagates_pkgfs_failure-component") {
component_name = "resolve-propagates-pkgfs-failure"
manifest = "meta/resolve-propagates-pkgfs-failure.cmx"
deps = [ ":resolve_propagates_pkgfs_failure" ]
}
fuchsia_test_component("resolve_recovers_from_http_errors-component") {
component_name = "resolve-recovers-from-http-errors"
manifest = "meta/resolve-recovers-from-http-errors.cmx"
deps = [ ":resolve_recovers_from_http_errors" ]
}
fuchsia_test_component("resolve_resumes_blob_gets-component") {
component_name = "resolve-resumes-blob-gets"
manifest = "meta/resolve-resumes-blob-gets.cmx"
deps = [ ":resolve_resumes_blob_gets" ]
}
fuchsia_test_component("resolve_fails-component") {
component_name = "resolve-fails"
manifest = "meta/resolve-fails.cmx"
deps = [ ":resolve_fails" ]
}
fuchsia_test_component("resolve_succeeds-component") {
component_name = "resolve-succeeds"
manifest = "meta/resolve-succeeds.cmx"
deps = [ ":resolve_succeeds" ]
}
fuchsia_test_component("resolve_succeeds_with_broken_minfs-component") {
component_name = "resolve-succeeds-with-broken-minfs"
manifest = "meta/resolve-succeeds-with-broken-minfs.cmx"
deps = [ ":resolve_succeeds_with_broken_minfs" ]
}
fuchsia_test_component("system_cache_fallback-component") {
component_name = "system-cache-fallback"
manifest = "meta/system-cache-fallback.cmx"
deps = [ ":system_cache_fallback" ]
}
fuchsia_test_component("base_pinning-component") {
component_name = "base-pinning"
manifest = "meta/base-pinning.cmx"
deps = [ ":base_pinning" ]
}
fuchsia_test_component("metrics-component") {
component_name = "metrics"
manifest = "meta/metrics.cmx"
deps = [ ":metrics" ]
}
renamed_binary("pkgsvr-binary") {
dest = "bin/pkgsvr"
source = "$root_out_dir/grand_unified_binary"
source_deps = [ "//src/go/grand_unified_binary" ]
}
renamed_binary("pkg_resolver-binary") {
dest = "bin/pkg_resolver"
source = "$root_out_dir/grand_swd_binary"
source_deps = [ "//src/sys/pkg/bin/grand-swd-binary" ]
}
fuchsia_component("pkg_resolver-component") {
component_name = "pkg-resolver"
deps = [ ":pkg_resolver-binary" ]
manifest = "//src/sys/pkg/bin/pkg-resolver/meta/pkg-resolver-isolated.cmx"
}
fuchsia_component("pkg_local_mirror-component") {
component_name = "pkg-local-mirror"
manifest = "//src/sys/pkg/bin/pkg-local-mirror/meta/pkg-local-mirror.cmx"
deps = [ "//src/sys/pkg/bin/pkg-local-mirror:bin" ]
}
fuchsia_component("pkg_cache-component") {
component_name = "pkg-cache"
manifest = "//src/sys/pkg/bin/pkg-cache/meta/pkg-cache-isolated.cmx"
deps = [ "//src/sys/pkg/bin/pkg-cache:bin" ]
}
resource("ca.cert-resource") {
sources = [ "//src/sys/pkg/lib/fuchsia-pkg-testing/certs/ca.cert" ]
outputs = [ "data/ssl/cert.pem" ]
}
fuchsia_test_package("pkg-resolver-integration-tests") {
test_components = [
":base_pinning-component",
":dynamic_repositories_disabled-component",
":dynamic_rewrite_disabled-component",
":get_hash-component",
":metrics-component",
":pkg_resolve_inspect-component",
":resolve_fails-component",
":resolve_propagates_pkgfs_failure-component",
":resolve_recovers_from_http_errors-component",
":resolve_resumes_blob_gets-component",
":resolve_succeeds-component",
":resolve_succeeds_with_broken_minfs-component",
":system_cache_fallback-component",
]
deps = [
":ca.cert-resource",
":empty-repo",
":pkg_cache-component",
":pkg_local_mirror-component",
":pkg_resolver-component",
# binaries that are used at runtime.
":pkgsvr-binary",
"//src/storage/bin/blobfs",
"//src/sys/pkg/bin/pm:pm_bin",
]
test_specs = {
log_settings = {
max_severity = "ERROR"
}
}
}
group("tests") {
testonly = true
public_deps = [
":pkg-resolver-integration-tests",
"//src/lib/storage/ramdevice_client:ramdisk-isolated-devmgr",
"//src/sys/pkg/bin/pm:pm",
]
}
resource_tree("empty-repo") {
testonly = true
sources_root = "template"
sources = [
"keys/root.json",
"keys/snapshot.json",
"keys/targets.json",
"keys/timestamp.json",
"repository/1.root.json",
"repository/1.snapshot.json",
"repository/1.targets.json",
"repository/root.json",
"repository/snapshot.json",
"repository/targets.json",
"repository/timestamp.json",
]
dest_dir = "empty-repo"
}