-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (39 loc) · 1.05 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
name: test
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
go: ["1.19", "1.20"]
runs-on: ${{ matrix.os }}
continue-on-error: true
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v4
- name: Set up Go 1.20
uses: actions/setup-go@v4
with:
go-version: "1.20"
- name: Get dependencies
run: |
go mod download
- name: Test
run: |
go test -race -coverprofile=coverage.txt -covermode=atomic ./...
# - name: Codecov
# uses: codecov/codecov-action@v2.0.3
# with:
# token: ${{secrets.CODECOV_TOKEN}}
# - name: Golint
# run: |
# curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b $GOPATH/bin v1.10.2
# go get -u golang.org/x/lint/golint
# golangci-lint run
# golint -set_exit_status