blob: edbe9c4d9ae2e8707e9bbd16fef95eb99c8f4794 [file] [log] [blame]
# Copyright 2018 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/board.gni")
declare_args() {
# Whether to include tests that are known to fail on NUC with ASan.
# Should be set to false in the infra builders that have board == "x64" and
# "asan" in variants.
include_tests_that_fail_on_nuc_asan = true
# The list of environment names to include in "basic_envs".
basic_env_names = [ "emu" ]
}
_all_named_fuchsia_envs = []
_all_named_host_envs = []
### Individual test environments
# Please keep alphabetized.
aemu_env = {
dimensions = {
device_type = "AEMU"
}
}
_all_named_fuchsia_envs += [
{
name = "aemu"
env = aemu_env
},
]
astro_env = {
dimensions = {
device_type = "Astro"
}
}
_all_named_fuchsia_envs += [
{
name = "astro"
env = astro_env
},
]
linux_env = {
dimensions = {
os = "Linux"
cpu = current_cpu
}
}
_all_named_host_envs += [
{
name = "linux"
env = linux_env
},
]
luis_env = {
dimensions = {
device_type = "Luis"
}
}
_all_named_fuchsia_envs += [
{
name = "luis"
env = luis_env
},
]
mac_env = {
dimensions = {
os = "Mac"
cpu = current_cpu
}
# When running tests for a mac build, we only wish to run mac tests; we attach
# the "mac" tag in that case to filter out other tests.
tags = [ "mac" ]
}
_all_named_host_envs += [
{
name = "mac"
env = mac_env
},
]
nelson_env = {
dimensions = {
device_type = "Nelson"
}
}
_all_named_fuchsia_envs += [
{
name = "nelson"
env = nelson_env
},
]
nuc_env = {
dimensions = {
device_type = "Intel NUC Kit NUC7i5DNHE"
}
}
_all_named_fuchsia_envs += [
{
name = "nuc"
env = nuc_env
},
]
qemu_env = {
dimensions = {
device_type = "QEMU"
}
}
_all_named_fuchsia_envs += [
{
name = "qemu"
env = qemu_env
},
]
sherlock_env = {
dimensions = {
device_type = "Sherlock"
}
}
_all_named_fuchsia_envs += [
{
name = "sherlock"
env = sherlock_env
},
]
vim3_env = {
dimensions = {
device_type = "Vim3"
}
}
_all_named_fuchsia_envs += [
{
name = "vim3"
env = vim3_env
},
]
gce_env = {
dimensions = {
device_type = "GCE"
}
}
_all_named_fuchsia_envs += [
{
name = "gce"
env = gce_env
},
]
atlas_env = {
dimensions = {
device_type = "Atlas"
}
}
_all_named_fuchsia_envs += [
{
name = "atlas"
env = atlas_env
},
]
### END Individual test environments
### Aliases ###
if (current_os == "linux") {
host_env = linux_env
} else if (current_os == "mac") {
host_env = mac_env
}
# Allow selection of AEMU as the default EMU.
emu_env = qemu_env
if (target_cpu == "x64") {
emu_env = {
}
emu_env = aemu_env
}
_all_named_fuchsia_envs += [
{
name = "emu"
env = emu_env
},
]
with_display_envs = [
aemu_env,
astro_env,
atlas_env,
luis_env,
nelson_env,
nuc_env,
sherlock_env,
# Re-enable once vim3 supports vulkan (https://fxbug.dev/75581)
# vim3_env,
]
chromebook_envs = [ atlas_env ]
### Select environment lists ###
# Tests that fail on a NUC in ASan but otherwise want to run on a NUC should
# use this.
nuc_env_fails_on_asan = []
if (include_tests_that_fail_on_nuc_asan) {
nuc_env_fails_on_asan += [ nuc_env ]
}
all_fuchsia_envs = []
foreach(named_env, _all_named_fuchsia_envs) {
all_fuchsia_envs += [ named_env.env ]
}
basic_envs = []
foreach(name, basic_env_names) {
foreach(named_env, _all_named_fuchsia_envs + _all_named_host_envs) {
if (name == named_env.name) {
basic_envs += [ named_env.env ]
}
}
}