Skip to content

Commit

Permalink
.github: set pipefail for benchmarks
Browse files Browse the repository at this point in the history
This avoids tee overriding the exit code when a
benchmark fails.
  • Loading branch information
jzelinskie committed Jun 23, 2023
1 parent 7f1a996 commit 4474adc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/build-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,9 @@ jobs:
with:
go-version: "${{ env.GO_VERSION }}"
- name: "Benchmark"
run: "go run mage.go test:bench | tee benchmarks.txt"
run: |
set -o pipefail # Don't let tee replace the exit-code
go run mage.go test:bench | tee benchmarks.txt
- name: "Download previous benchmark data"
uses: "actions/cache@v1"
with:
Expand Down

0 comments on commit 4474adc

Please sign in to comment.