V2 #940
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: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - master | |
| jobs: | |
| run-tests: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| id-token: write # Required to fetch the OIDC token | |
| steps: | |
| - name: Set up Go 1.x | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version: '1.25' | |
| - name: Check out code into the Go module directory | |
| uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 1 | |
| ref: ${{ github.event.pull_request.head.sha }} | |
| - name: Build the binary | |
| run: just build | |
| - name: Setup tests | |
| run: just test-setup | |
| env: | |
| CODE_PATH: /home/runner/code | |
| - name: Run tests | |
| run: just test | |
| env: | |
| CODE_PATH: /home/runner/code | |
| - name: Report test coverage to DeepSource | |
| run: | | |
| curl https://deepsource.io/cli | sh | |
| ./bin/deepsource report --analyzer test-coverage --key go --value-file ./coverage.out --use-oidc |