-
Notifications
You must be signed in to change notification settings - Fork 5
52 lines (45 loc) · 1.21 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: tests
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build-and-test:
runs-on: ubuntu-latest
strategy:
matrix:
go: [ '1.16', '1.17', '1.18', '1.19' ]
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # need tags for `git describe`
- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go }}
- name: Build
run: make
- name: Test
run: make check SKIP_STATIC_CHECK=true
- name: Translate coverage report
uses: jandelgado/gcov2lcov-action@v1.0.8
with:
infile: test/cov.cov
outfile: test/cov.lcov
- name: Submit coverage report
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: test/cov.lcov
flag-name: go-${{ matrix.go }}
parallel: true
finish:
needs: build-and-test
runs-on: ubuntu-latest
steps:
- name: Finalize coverage report
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true