Proposal(Need Discussion): Show code coverage every time you submit a PR
What Would You Like to Add? Why Is This Needed?
I found an interesting link to code showing coverage, as shown this link https://github.com/coverallsapp/github-action, feels cool
Design
1 add the action of unit tests to the github workflow
- name: Run unit tests
run: make test
2 add the action of coveralls to the github workflow
- name: Install goveralls
run: go install github.com/mattn/goveralls@latest
- name: Send coverage
env:
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: goveralls -coverprofile=covprofile -service=githuh
3 add final job to the github workflow
finish:
needs: test
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true
Anything else
Please join us to discuss! 🙌
I think it's great! Any CI that contributes to enhanced code robustness is advocated.
@iyear care to contribute a PR for this issue?
@rxhuster Would you mind contributing a PR for this? If you are too busy to write it, please feel free to contact me and I will help you to implement this proposal :).
@rxhuster Would you mind contributing a PR for this? If you are too busy to write it, please feel free to contact me and I will help you to implement this proposal :).
ok,i wii try
@rxhuster May I ask if you are still working on it? If you encounter some difficulties or don't have time to do it, feel free to contact me and I will help you to finish it.