| 1 |
name: Linux Test |
| 2 |
|
| 3 |
on: |
| 4 |
push: |
| 5 |
branches: |
| 6 |
- "*" |
| 7 |
pull_request: |
| 8 |
branches: |
| 9 |
- "*" |
| 10 |
|
| 11 |
jobs: |
| 12 |
build: |
| 13 |
strategy: |
| 14 |
matrix: |
| 15 |
go-version: ["1.18", "1.19", "1.20"] |
| 16 |
runs-on: ubuntu-latest |
| 17 |
|
| 18 |
steps: |
| 19 |
- name: Set up Go |
| 20 |
uses: actions/setup-go@v3 |
| 21 |
with: |
| 22 |
go-version: ${{ matrix.go-version }} |
| 23 |
id: go |
| 24 |
|
| 25 |
- name: Check out code into the Go module directory |
| 26 |
uses: actions/checkout@v3 |
| 27 |
|
| 28 |
- name: Run tests |
| 29 |
run: go test -v -race ./... |
| 30 |
|
| 31 |
# Although this package doesn't support Windows, we want to verify that |
| 32 |
# everything builds properly. |
| 33 |
- name: Verify build for non-UNIX platforms |
| 34 |
run: go build |
| 35 |
env: |
| 36 |
GOOS: windows |