| # 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/dart/test.gni") |
| import("//build/testing/host_test_data.gni") |
| |
| dart_test("flash_test") { |
| sources = [ "flash_test.dart" ] |
| deps = [ |
| "//sdk/testing/sl4f/client", |
| "//third_party/dart-pkg/pub/test", |
| ] |
| non_dart_deps = [ ":test_deps($host_toolchain)" ] |
| environments = [ |
| { |
| dimensions = { |
| device_type = "Astro" |
| } |
| |
| # Add a tag to make sure this does not run in all builders. |
| tags = [ "flash-tests" ] |
| |
| # This is only present to force this test to run in its own shard. |
| service_account = |
| "internal-artifacts-readers@fuchsia-infra.iam.gserviceaccount.com" |
| }, |
| ] |
| } |
| |
| if (is_host) { |
| host_test_data("test_deps") { |
| sources = [ |
| "$root_build_dir/firmware.img", |
| "$root_build_dir/firmware_bl2.img", |
| "$root_build_dir/flash.sh", |
| "$root_build_dir/fuchsia.vbmeta", |
| "$root_build_dir/fuchsia.zbi.signed", |
| "$root_build_dir/host_x64/fastboot", |
| "$root_build_dir/obj/build/images/fvm.fastboot.blk", |
| "$root_build_dir/zedboot.vbmeta", |
| "$root_build_dir/zedboot.zbi.signed", |
| ] |
| } |
| } |
| |
| group("tests") { |
| testonly = true |
| if (board_name == "astro") { |
| deps = [ ":flash_test($host_toolchain)" ] |
| } |
| } |