Add CodSpeed performance benchmarking integration #7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CodSpeed Performance Benchmarks | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: null | |
| permissions: | |
| contents: read | |
| id-token: write | |
| jobs: | |
| benchmarks: | |
| name: Run Go Benchmarks with CodSpeed | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version: "1.13" | |
| - name: Get dependencies | |
| run: | | |
| go mod download | |
| go mod verify | |
| - name: Run benchmarks with CodSpeed | |
| uses: CodSpeedHQ/[email protected] | |
| with: | |
| upload-url: ${{ secrets.CODSPEED_STAGING_UPLOAD_URL }} | |
| run: go test -bench=. -benchmem ./... |