| 1 |
name: Test |
| 2 |
|
| 3 |
on: |
| 4 |
push: |
| 5 |
branches: |
| 6 |
- master |
| 7 |
pull_request: |
| 8 |
|
| 9 |
jobs: |
| 10 |
test: |
| 11 |
runs-on: ubuntu-22.04 |
| 12 |
strategy: |
| 13 |
matrix: |
| 14 |
go: |
| 15 |
- '1.17' |
| 16 |
- '1.18' |
| 17 |
- '1.19' |
| 18 |
name: test go-${{ matrix.go }} |
| 19 |
steps: |
| 20 |
- uses: actions/checkout@v3 |
| 21 |
- uses: actions/setup-go@v3 |
| 22 |
with: |
| 23 |
go-version: ${{ matrix.go }} |
| 24 |
- name: run test |
| 25 |
run: go test -v -race ./... |
| 26 |
env: |
| 27 |
GO111MODULE: on |
| 28 |
lint: |
| 29 |
runs-on: ubuntu-22.04 |
| 30 |
name: lint |
| 31 |
steps: |
| 32 |
- uses: actions/checkout@v3 |
| 33 |
- name: golangci-lint |
| 34 |
uses: golangci/golangci-lint-action@537aa1903e5d359d0b27dbc19ddd22c5087f3fbc |
| 35 |
with: |
| 36 |
version: v1.48.0 |