-
-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (38 loc) · 1.03 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
name: Run Tests
on: [push, pull_request]
jobs:
linux:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
go-version: [1.19.x]
steps:
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
id: go
- name: Set up Go modules cache
uses: actions/cache@v3
env:
cache-name: cache-go-modules
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go${{ matrix.go-version }}-build-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go${{ matrix.go-version }}-build-${{ env.cache-name }}-
${{ runner.os }}-go${{ matrix.go-version }}-build-
${{ runner.os }}-go${{ matrix.go-version }}-
- name: Check out code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
args: --issues-exit-code=0
- name: Run tests
run: |
make build
make cover