build: don't bust Bazel analysis cache when switching between build & test (#48694)

`test` inherits from `build` in bazelrc so it is sufficient to specify
`build` to get the flag set for both `bazel build` and `bazel test`
This commit is contained in:
Greg Magolan 2023-03-06 00:43:23 -08:00 committed by GitHub
parent adc006d905
commit 76b67833cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -15,5 +15,5 @@ import %workspace%/.aspect/bazelrc/performance.bazelrc
# this file. See https://bazel.build/configure/best-practices#bazelrc-file.
try-import %workspace%/.aspect/bazelrc/user.bazelrc
# Enable bazel hack for autogold
test --test_env=ENABLE_BAZEL_PACKAGES_LOAD_HACK=true
# Enable bazel hack for autogold; apply to both build & test to avoid busting analysis cache
build --test_env=ENABLE_BAZEL_PACKAGES_LOAD_HACK=true