-
Notifications
You must be signed in to change notification settings - Fork 199
Code coverage for existing unit tests #3737
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
base: master
Are you sure you want to change the base?
Code coverage for existing unit tests #3737
Conversation
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: chethanv28 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/ok-to-test |
eff4de3 to
bdecb15
Compare
|
Triggering CSI-WCP Pre-checkin Pipeline for this PR... Job takes approximately an hour to complete |
|
SUCCESS --- Jenkins Build #592 |
|
/test pull-vsphere-csi-driver-verify-golangci-lint |
What this PR does / why we need it:
PR is adding Code coverage analysis for existing unit tests & then use the summary in make build.
As of today we have a very low overall code coverage. So, adding a check for overall code coverage does not make sense. But for the existing unit tests & any new tests that get added in the future we will have threshold of 75% coverage in amek build process itself.
The make build will execute the below steps:
✅ Compile the binaries
✅ Run unit tests with coverage
✅ Validate that tested functions have good coverage (≥75%) (For existing unit tests or any new unit tests that get added)
❌ Fail the build if code coverage drops below 75% For existing unit tests or any new unit tests that get added)
This is not a PR to increase the code coverage but intent is to introduce the code coverage analysis tool for every new check-in from now on.
We will continue to print the below summary until we reach overall coverage goal of 75~80%
Testing done:
$ make build
Special notes for your reviewer:
Release note: