mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
Sets up the Bazel integration test with the new integration rule. This commit is separate from the other changes because it required some additional work. i.e. The test has moved from `integration/bazel` to `integration/<..>/bazel` where `<..>` is a new Bazel package defining the integration test. This is necessary because we could not declare the integration test within the `BUILD.bazel` file actually being part of the nested bazel workspace. In those cases we can just define it at a higher-level and use integration test `working_dir` attribute. PR Close #44238
23 lines
1,023 B
Text
23 lines
1,023 B
Text
load("//integration:index.bzl", "ng_integration_test")
|
|
|
|
package(default_visibility = ["//visibility:public"])
|
|
|
|
ng_integration_test(
|
|
name = "bazel_ngtsc_plugin_test",
|
|
srcs = glob(["bazel_ngtsc_plugin/**"]),
|
|
environment = {
|
|
# Setup a HOME directory so that Bazelisk can work, both Linux/macOS and Windows variants
|
|
# are configured to provide a fake home directory so that Bazelisk can download Bazel.
|
|
"HOME": "<TMP>",
|
|
"LOCALAPPDATA": "<TMP>",
|
|
},
|
|
tags = [
|
|
# Bazel-in-bazel tests are resource intensive and should not be over-parallelized
|
|
# as they will compete for the resources of other parallel tests slowing
|
|
# everything down. Ask Bazel to allocate multiple CPUs for these tests with "cpu:n" tag.
|
|
"cpu:3",
|
|
],
|
|
# Nested bazel workspace tests need to be declared at a higher-level because the test
|
|
# cannot be wired up within the `BUILD.bazel` file as part of the actual test workspace.
|
|
working_dir = "bazel_ngtsc_plugin/",
|
|
)
|