fea: add coverage actions

This commit is contained in:
Daniel Ding
2022-09-23 02:48:11 +00:00
committed by Daniel Ding
parent 69973f11e3
commit d5b1a7fc30
6 changed files with 60 additions and 13 deletions
+29
View File
@@ -0,0 +1,29 @@
name: Coverage CI
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup golang
uses: actions/setup-go@v3
with:
go-version: '1.16.x'
- name: Generate coverage report
run: make cover
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: ./coverage.cov
name: codecov
verbose: true