| # 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("//src/graphics/lib/magma/gnbuild/magma.gni") |
| |
| executable("mali_vulkan_test_bin") { |
| testonly = true |
| output_name = "mali_vulkan_test" |
| |
| sources = [ "mali_vulkan_test.cc" ] |
| |
| deps = [ |
| "//src/graphics/tests/common", |
| "//src/lib/fxl/test:gtest_main", |
| "//src/lib/vulkan", |
| "//third_party/github.com/ARM-software/HWCPipe:mali_profiler", |
| "//third_party/googletest:gtest", |
| "//zircon/system/ulib/trace", |
| "//zircon/system/ulib/zx", |
| ] |
| |
| # HWCPipe uses exceptions to report errors, so they must be left enabled. |
| configs -= [ "//build/config:no_exceptions" ] |
| } |
| |
| fuchsia_test_component("mali_vulkan_test_cmp") { |
| deps = [ |
| ":mali_vulkan_test_bin", |
| "//src/lib/vulkan/validation_layers", |
| ] |
| component_name = "mali_vulkan_test" |
| manifest = "meta/mali_vulkan_test.cml" |
| test_type = "system" |
| } |
| |
| protected_libvulkan_envs = [] |
| |
| # Filter out everything that's not astro, sherlock, or nelson. |
| foreach(env, magma_libvulkan_hardware_envs) { |
| if (env == sherlock_env || env == astro_env || env == nelson_env) { |
| protected_libvulkan_envs += [ env ] |
| } |
| } |
| |
| fuchsia_test_package("mali-vulkan-test-pkg") { |
| test_components = [ ":mali_vulkan_test_cmp" ] |
| package_name = "mali_vulkan_test" |
| test_specs = { |
| environments = protected_libvulkan_envs |
| } |
| } |
| |
| group("mali_vulkan_test") { |
| testonly = true |
| deps = [ ":mali-vulkan-test-pkg" ] |
| } |