test: raise statement coverage above 80% and add CI coverage gate#396
Draft
joshua-temple wants to merge 1 commit into
Draft
test: raise statement coverage above 80% and add CI coverage gate#396joshua-temple wants to merge 1 commit into
joshua-temple wants to merge 1 commit into
Conversation
b7f5f89 to
d96c849
Compare
1646254 to
659a0c3
Compare
d96c849 to
868951f
Compare
Signed-off-by: Joshua Temple <joshua.temple@stablekernel.com>
659a0c3 to
5a49f23
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
cascade computes test coverage in CI but only echoes it to the log: there is no enforced threshold and no public signal. Overall statement coverage sits at 77.4%, below the 80% needed for the OpenSSF Best Practices
test_statement_coverage80(Silver) criterion.Stacked on #395.
Fix
promote,hotfix,reset,orchestrate,rollback,release,changelog,version).pr.yamlandvalidate.yaml: after the existing coverage computation, fail the job if total statement coverage drops below 80%.The gate is self-contained (an awk comparison on
go tool cover -funcoutput); no external coverage service or secret is required.Verification
go build ./...passes.go test -race ./...passes on all touched packages.golangci-lint run ./...clean;actionlintclean on both workflows.Notes