-
Notifications
You must be signed in to change notification settings - Fork 807
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add code coverage report #1932
Add code coverage report #1932
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -76,6 +76,13 @@ clean: | |
test: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would prefer a separate target (perhaps There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added new target as requested: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh I just realized while |
||
go test -v -race ./cmd/... ./pkg/... | ||
|
||
.PHONY: test/coverage | ||
test/coverage: | ||
go test -coverprofile=cover.out ./cmd/... ./pkg/... | ||
grep -v "mock" cover.out > filtered_cover.out | ||
go tool cover -html=filtered_cover.out -o coverage.html | ||
rm cover.out filtered_cover.out | ||
|
||
.PHONY: test-sanity | ||
test-sanity: | ||
go test -v -race ./tests/sanity/... | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Top level comment: Consider adding a section to local-development section of our makefile documentation. Perhaps something like:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks - added ✅