Skip to content

Commit

Permalink
github: add ci workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
johnlettman committed Jul 15, 2024
1 parent 7a7bd4e commit 2e3f0e1
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
on:
pull_request:
branches:
- main
paths-ignore:
- "**/*.md"
- "**/*.py"
- "LICENSE"

jobs:
test:
runs-on: ubuntu-latest

strategy:
matrix:
go-version: [ '1.22.5' ]

steps:
- uses: actions/checkout@v2
- name: Setup Go ${{ matrix.go-version }}
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Install dependencies
run: go get .
- name: Test
run: |
go install github.com/jstemmer/go-junit-report/v2@latest
go test -short -timeout 120s -race -count 1 -v ./... 2>&1 | go-junit-report -set-exit-code -iocopy -out "${{ github.workspace }}/report.xml"
- name: Test summary
uses: test-summary/action@v2
with:
paths: |
${{ github.workspace }}/report.xml
if: always()
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
token: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 2e3f0e1

Please sign in to comment.