-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (28 loc) · 886 Bytes
/
ci.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: ci
on: [ push ]
jobs:
test:
name: unit-tests
runs-on: ubuntu-latest
steps:
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: 1.18
- name: checkout the code
uses: actions/checkout@v3
- name: preparing git config
env:
GITHUB_USER: ${{ secrets.DYORM_GITHUB_USER }}
GITHUB_TOKEN: ${{ secrets.DYORM_GITHUB_TOKEN }}
run: git config --global url."https://$GITHUB_USER:$GITHUB_TOKEN@github.com/".insteadOf "https://github.com/"
- name: fetch dependencies
run: go mod download
- name: run test race with coverage
run: make coverage-badge
- name: Upload coverage report
uses: codecov/codecov-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.txt
fail_ci_if_error: true