-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (33 loc) · 935 Bytes
/
coverall.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
name: Coverall
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
name: Test with Coverage
runs-on: ubuntu-latest
steps:
- name: "Set git to use LF"
run: |
git config --global core.autocrlf false
git config --global core.eol lf
- name: "Checkout code"
uses: actions/checkout@v3
- name: "Set up Go"
uses: actions/setup-go@v3
with:
go-version-file: 'go.mod'
cache: true
- name: "Unit tests"
uses: magefile/mage-action@3b833fb24c0d19eed3aa760b9eb285b4b84f420f
with:
version: latest
args: test:unit
- name: "Install goveralls"
run: go install github.com/mattn/goveralls@latest
- name: "Send coverage"
env:
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: goveralls -coverprofile=coverage.out -service=github