Skip to content

Commit

Permalink
Specify the Bazel output location for MacOS actions for caching.
Browse files Browse the repository at this point in the history
The default location (/private/var/tmp) may contain other temporary and unrelated files.

Also, set the platform_suffix for noriegeli + asan tests for better caching behavior.

PiperOrigin-RevId: 681506377
  • Loading branch information
xinhaoyuan authored and copybara-github committed Oct 2, 2024
1 parent 0021f30 commit e6fe25c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/bazel_test_centipede.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:
- name: Run puzzles without Riegeli with ASAN
if: matrix.config == 'noriegeli'
run: |
bazel test --no//fuzztest:use_riegeli --test_output=errors --linkopt=-fsanitize=address --copt=-fsanitize=address centipede/puzzles:all
bazel test --no//fuzztest:use_riegeli --test_output=errors --linkopt=-fsanitize=address --copt=-fsanitize=address --platform_suffix=asan centipede/puzzles:all
- name: Save new cache based on main
if: github.ref == 'refs/heads/main'
uses: actions/cache/save@v4
Expand Down Expand Up @@ -109,20 +109,20 @@ jobs:
run: |
# Timed wait is delayed for unknown reasons in MacOS for a few testing
# environments, thus disabling a few related non-critical tests.
bazel test --local_test_jobs=1 --test_output=errors --no//fuzztest:use_riegeli -- centipede:all -centipede:periodic_action_test -centipede:rusage_profiler_test && \
bazel test --local_test_jobs=1 --test_output=errors --no//fuzztest:use_riegeli --test_filter='-*ValidateTimelapseSnapshots' -- centipede:rusage_profiler_test
bazel --output_user_root="${HOME}/.cache/bazel" test --local_test_jobs=1 --test_output=errors --no//fuzztest:use_riegeli -- centipede:all -centipede:periodic_action_test -centipede:rusage_profiler_test && \
bazel --output_user_root="${HOME}/.cache/bazel" test --local_test_jobs=1 --test_output=errors --no//fuzztest:use_riegeli --test_filter='-*ValidateTimelapseSnapshots' -- centipede:rusage_profiler_test
- name: Run e2e tests without Riegeli
if: ${{ !cancelled() }}
run: |
bazel test --test_output=errors --no//fuzztest:use_riegeli centipede/testing:instrumentation_test centipede/testing:runner_test centipede/testing:multi_dso_test
bazel --output_user_root="${HOME}/.cache/bazel" test --test_output=errors --no//fuzztest:use_riegeli centipede/testing:instrumentation_test centipede/testing:runner_test centipede/testing:multi_dso_test
- name: Run puzzles without Riegeli
if: ${{ !cancelled() }}
run: |
bazel test --test_output=errors --no//fuzztest:use_riegeli centipede/puzzles:all
bazel --output_user_root="${HOME}/.cache/bazel" test --test_output=errors --no//fuzztest:use_riegeli centipede/puzzles:all
- name: Run puzzles without Riegeli with ASAN
if: ${{ !cancelled() }}
run: |
bazel test --test_output=errors --no//fuzztest:use_riegeli --linkopt=-fsanitize=address --copt=-fsanitize=address --platform_suffix=asan centipede/puzzles:all
bazel --output_user_root="${HOME}/.cache/bazel" test --test_output=errors --no//fuzztest:use_riegeli --linkopt=-fsanitize=address --copt=-fsanitize=address --platform_suffix=asan centipede/puzzles:all
- name: Save new cache based on main
if: github.ref == 'refs/heads/main'
uses: actions/cache/save@v4
Expand Down

0 comments on commit e6fe25c

Please sign in to comment.