-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (44 loc) · 1.03 KB
/
test.yml
File metadata and controls
55 lines (44 loc) · 1.03 KB
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
53
54
55
name: Test
on:
push:
branches:
- master
paths-ignore:
- '**.md'
pull_request:
branches:
- master
paths-ignore:
- '**.md'
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Run golangci-lint
uses: actions-contrib/golangci-lint@v1
with:
golangci_lint_version: v1.13
test:
name: Test
runs-on: ubuntu-latest
strategy:
matrix:
go: [ '1.14', '1.13' ]
steps:
- name: Set up Go ${{ matrix.go }}
uses: actions/setup-go@v1
with:
go-version: ${{ matrix.go }}
- name: Check out code into the Go module directory
uses: actions/checkout@v2
- name: Get dependencies
run: go mod download
- name: Test
run: go test -v -race -coverprofile=coverage.txt -covermode=atomic
- uses: codecov/codecov-action@v1
if: matrix.go == '1.14'
with:
file: ./coverage.txt
fail_ci_if_error: true