Skip to content

chores: update CI badge #3

chores: update CI badge

chores: update CI badge #3

Workflow file for this run

name: Test
on:
pull_request:
paths:
- "**.go"
- go.mod
- go.sum
- ".github/workflows/test.yaml"
- ".golangci.yaml"
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
- name: Run lint check
uses: reviewdog/action-golangci-lint@v2
with:
reporter: github-pr-review
go_version_file: go.mod
test:
strategy:
matrix:
go-version: [oldstable, stable]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
- name: Run tests
run: go test -tags='!fuzz' -race -failfast -coverpkg=./... -coverprofile="coverage.txt" -covermode=atomic ./...
- name: Codecov
if: matrix.os == 'ubuntu-latest' && matrix.go-version == 'stable'
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}