-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix: update coverage upload * fix: update github workflow * fix: using coverage.out * fix: using coverage.out in coverage CI workflow * fix: exclude some folder should not matter to test
- Loading branch information
1 parent
7fe6e56
commit dbca23d
Showing
3 changed files
with
36 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -75,4 +75,3 @@ jobs: | |
cache: true | ||
- name: Run tests and generate coverage report | ||
run: make test | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Coverage | ||
on: [push, pull_request] | ||
jobs: | ||
test: | ||
name: Test with Coverage | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Go | ||
uses: actions/setup-go@v2 | ||
with: | ||
go-version: '1.22' | ||
- name: Check out code | ||
uses: actions/checkout@v2 | ||
- name: Install dependencies | ||
run: | | ||
go mod download | ||
- name: Run Unit tests | ||
run: | | ||
make test | ||
- name: Install goveralls | ||
run: go install github.com/mattn/goveralls@latest | ||
- name: Send coverage | ||
env: | ||
COVERALLS_TOKEN: ${{ secrets.COVERALLS_TOKEN }} | ||
run: goveralls -coverprofile=coverage.out -service=github | ||
# or use shogo82148/actions-goveralls | ||
# - name: Send coverage | ||
# uses: shogo82148/actions-goveralls@v1 | ||
# with: | ||
# path-to-profile: covprofile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters