upload coverage to codecov.io#84
Conversation
Signed-off-by: qmuntal <qmuntaldiaz@microsoft.com>
Codecov Report
@@ Coverage Diff @@
## main #84 +/- ##
=======================================
Coverage ? 89.74%
=======================================
Files ? 10
Lines ? 985
Branches ? 0
=======================================
Hits ? 884
Misses ? 67
Partials ? 34 Continue to review full report at Codecov.
|
SteveLasker
left a comment
There was a problem hiding this comment.
Thanks @qmuntal,
LGTM
| - name: Go Coverage | ||
| run: | | ||
| go version | ||
| go test -short -cover | grep "^.*coverage:.*of statements$" | python -c "import os,re,sys; cover_rpt = sys.stdin.read(); print(cover_rpt) if len(cover_rpt) != 0 and len(cover_rpt.splitlines()) == 1 else sys.exit(1); min_cover = float(re.findall(r'\d*\.\d+|\d+', os.environ['GITHUB_WORKFLOW'])[0]); cover = float(re.findall(r'\d*\.\d+|\d+', cover_rpt)[0]); sys.exit(1) if (cover > 100) or (cover < min_cover) else sys.exit(0)" |
There was a problem hiding this comment.
Should we retain the cover >= 89% check to ensure we always have coverage >= 89%? It seems codecov does not provide this functionality.
There was a problem hiding this comment.
Good catch, forgot to do that. Codecov does support minimum coverage checks: https://docs.codecov.com/docs/commit-status. I'm trying to set it up.
Signed-off-by: qmuntal <qmuntaldiaz@microsoft.com>
Signed-off-by: qmuntal <qmuntaldiaz@microsoft.com>
Fix #50
Signed-off-by: qmuntal qmuntaldiaz@microsoft.com