Debian Codegraph @

.github/workflows/build-and-test.yml

raw
1 name: Build and Test
2 on:
3 pull_request:
4 jobs:
5 build:
6 runs-on: ubuntu-latest
7 strategy:
8 matrix:
9 go: [ '1.17', '1.16' ]
10 name: Go ${{ matrix.go }} build
11 steps:
12 - uses: actions/checkout@v2
13 with:
14 fetch-depth: 0
15 - name: Setup Go
16 uses: actions/setup-go@v2
17 with:
18 go-version: ${{ matrix.go }}
19 - name: Build and Test
20 run: |
21 go build
22 go test -race -coverprofile=profile.cov ./...
23 - name: Send coverage
24 uses: shogo82148/actions-goveralls@v1
25 with:
26 path-to-profile: profile.cov
27 flag-name: Go-${{ matrix.go }}
28 parallel: true
29 coverage:
30 needs: build
31 name: Test Coverage
32 runs-on: ubuntu-latest
33 steps:
34 - uses: shogo82148/actions-goveralls@v1
35 with:
36 parallel-finished: true