| # Copyright 2025 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") |
| |
| group("camera") { |
| testonly = true |
| deps = [ |
| ":settings_camera", |
| ":tests", |
| ] |
| } |
| |
| rustc_library("settings_camera") { |
| name = "settings_camera" |
| with_unit_tests = true |
| edition = "2021" |
| |
| visibility = [ |
| ":*", |
| "//src/settings/light:*", |
| "//src/settings/service:*", |
| ] |
| |
| deps = [ |
| "//sdk/fidl/fuchsia.camera3:fuchsia.camera3_rust", |
| "//sdk/rust/zx", |
| "//src/lib/fidl/rust/fidl", |
| "//src/lib/fuchsia-async", |
| "//src/settings/common:settings_common", |
| "//third_party/rust_crates:anyhow", |
| "//third_party/rust_crates:futures", |
| ] |
| |
| test_deps = [] |
| |
| sources = [ "src/lib.rs" ] |
| |
| configs -= [ "//build/config/rust/lints:allow_unused_results" ] |
| configs += [ "//build/config/rust/lints:clippy_warn_all" ] |
| } |
| |
| fuchsia_unittest_package("settings_camera_tests") { |
| component_name = "settings_camera_test" |
| manifest = "meta/settings_camera_tests.cml" |
| deps = [ ":settings_camera_test" ] |
| test_specs = { |
| log_settings = { |
| max_severity = "ERROR" |
| } |
| } |
| } |
| |
| group("tests") { |
| testonly = true |
| deps = [ ":settings_camera_tests" ] |
| } |