blob: 077fe816ff9bb753ae876a09b4c4aefc8d6cb747 [file] [log] [blame]
# Copyright 2023 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/testing/validated_test_types_group.gni")
assert(is_fuchsia, "These can only be defined in the default toolchain")
# For use with the 'hermetic_test_package_labels' GN build argument.
# WARNING: Known to infrastructure
validated_test_types_group("hermetic_tests") {
testonly = true
allowed_test_types = [ "hermetic" ]
deps = [
"//examples:hermetic_tests",
"//src/sys/component_manager:hermetic_tests",
]
}
# For use with the 'test_package_labels' GN build argument.
# WARNING: Known to infrastructure
group("non-hermetic_tests") {
testonly = true
deps = []
public_deps = []
data_deps = []
# Ensure that no tests are added to the non-hermetic tests group
assert(
deps + public_deps + data_deps == [],
"The minimal product does not support the running of non-hermetic tests in infra.")
}
# For use with the 'e2e_test_labels' GN build argument.
# WARNING: Known to infrastructure
group("e2e_tests") {
testonly = true
deps = []
public_deps = []
data_deps = []
# Ensure that no tests are added to the e2e_tests tests group
assert(
deps + public_deps + data_deps == [],
"The minimal product does not support the running of end-to-end tests in infra.")
}
# WARNING: Known to infrastructure
group("minimal") {
testonly = true
# The buildbot groups are not allowed to add platform features, only tests
# and tools.
assert_no_deps = [ "//bundles/platform/*" ]
deps = [
# All tests from the standardized test groups:
":e2e_tests",
":hermetic_tests",
":non-hermetic_tests",
# Additional non-test things to build:
":additional_build_targets",
# TODO(https://fxbug.dev/42081259): Migrate from this list to ":hermetic_tests", which
# will include all hermetic tests, including those from the targets below.
"//examples:tests",
"//sdk:tests",
"//src/connectivity/network:tests",
# TODO(https://fxbug.dev/42082585): Uncomment once all tests pass on minimal.x64.
# "//src/developer:tests",
"//src/bringup:tests",
"//src/devices:tests",
"//src/diagnostics:tests",
"//src/fonts:tests",
"//src/hwinfo:tests",
"//src/intl:tests",
"//src/lib:tests",
"//src/performance:tests",
"//src/power:tests",
"//src/starnix:tests",
"//src/storage:tests",
"//src/sys:tests",
"//src/ui:tests",
"//src/zircon:tests",
]
if (current_cpu == "riscv64") {
deps -= [
# TODO(https://fxbug.dev/42073578): Remove after removing Go dependencies on RISC-V.
"//src/connectivity/network:tests",
# TODO(https://fxbug.dev/292292675): Enable once all dependencies succeed on RISC-V.
# TODO(https://fxbug.dev/42082585): Uncomment when adding to the default targets.
# "//src/developer:tests",
]
deps += [
# Run a subset of the network tests until https://fxbug.dev/42073578 is addressed
# and all tests (removed above) can be built and run.
"//src/connectivity/network/tests:tests",
]
} else if (current_cpu == "x64") {
deps -= [
# The integration tests that require WebEngine fail when run. See
# https://fxbug.dev/42083237. Since they are only run on x64 (the test spec
# requires AEMU), disable them only for that architecture
# TODO(https://fxbug.dev/42081259): Remove once the corresponding entry above is
# replaced with a `hermetic_tests`.target.
"//src/ui:tests",
]
}
}
# Contains additional targets to be built that are not needed for tests.
# This allows bots to ensure buildable targets do not regress even if they are
# not being run by another bot (i.e., during bringup of a new CPU architecture).
group("additional_build_targets") {
testonly = true
deps = [ "//examples" ]
}