Debian Codegraph @

.github/workflows/test.yml

raw symbols SCIP
1 on:
2 push:
3 branches: [main]
4 pull_request:
5 name: Test
6 jobs:
7 test:
8 strategy:
9 matrix:
10 go-version: [1.25.x, 1.26.x]
11 platform: [ubuntu-latest, macos-latest, windows-latest]
12 package: [passthrough, extras]
13 runs-on: ${{ matrix.platform }}
14 defaults:
15 run:
16 shell: bash
17 steps:
18 - name: Install Go
19 uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
20 with:
21 go-version: ${{ matrix.go-version }}
22 cache: false
23 - name: Install staticcheck
24 if: matrix.platform == 'ubuntu-latest'
25 run: go install honnef.co/go/tools/cmd/staticcheck@latest
26 - name: Update PATH
27 run: echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
28 - name: Checkout code
29 uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5.0.1
30 - name: Fmt
31 if: matrix.platform != 'windows-latest'
32 run: "diff <(gofmt -d .) <(printf '')"
33 working-directory: ${{ matrix.package }}
34 - name: Vet
35 run: go vet ./...
36 working-directory: ${{ matrix.package }}
37 - name: Staticcheck
38 if: matrix.platform == 'ubuntu-latest'
39 run: staticcheck ./...
40 working-directory: ${{ matrix.package }}
41 - name: Test
42 run: go test -race ./...
43 working-directory: ${{ matrix.package }}