blob: 238d41194b5921ba63394a45cfd89c40e389bafb [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_library.gni")
rustc_library("blobfs") {
name = "blobfs"
with_unit_tests = true
edition = "2021"
deps = [
"//sdk/fidl/fuchsia.io:fuchsia.io_rust",
"//sdk/fidl/fuchsia.kernel:fuchsia.kernel_rust",
"//sdk/fidl/fuchsia.pkg:fuchsia.pkg_rust",
"//src/lib/fidl/rust/fidl",
"//src/lib/fuchsia-component",
"//src/lib/fuchsia-fs",
"//src/lib/zircon/rust:fuchsia-zircon",
"//src/storage/fxfs/fidl/fuchsia.fxfs:fuchsia.fxfs_rust",
"//src/storage/lib/delivery_blob",
"//src/storage/lib/vfs/rust:vfs",
"//src/storage/lib/vmo-blob",
"//src/sys/pkg/lib/fuchsia-hash",
"//third_party/rust_crates:anyhow",
"//third_party/rust_crates:futures",
"//third_party/rust_crates:thiserror",
"//third_party/rust_crates:tracing",
]
test_deps = [
"//src/lib/fuchsia-async",
"//src/sys/pkg/lib/fuchsia-merkle",
"//src/sys/pkg/testing/blobfs-ramdisk",
"//third_party/rust_crates:assert_matches",
"//third_party/rust_crates:maplit",
]
sources = [
"src/lib.rs",
"src/mock.rs",
]
configs += [ "//build/config/rust/lints:clippy_warn_all" ]
}
fuchsia_unittest_package("blobfs-lib-tests") {
manifest = "meta/blobfs-lib-test.cml"
deps = [
":blobfs_test",
"//src/storage/fxfs:fxfs_component",
"//src/storage/testing:storage_driver_test_realm",
]
test_specs = {
log_settings = {
max_severity = "ERROR"
}
}
}
group("tests") {
testonly = true
public_deps = [ ":blobfs-lib-tests" ]
}