fix: resolve .gomuignore and Not Viable mutation issues#46
Merged
Conversation
- Apply .gomuignore patterns to GetChangedFiles in git integration Previously, ignore patterns were only applied in GetAllGoFiles, causing incremental analysis to process ignored files - Fix compilation check to build entire package instead of single file Using `go build <file.go>` fails when the file depends on other package members. Changed to `go build .` with overlay to resolve all package dependencies correctly - Pass incremental option to IncrementalAnalyzer properly The incremental flag was hardcoded to true, ignoring CLI option - Re-enable mutation-testing quality gate (threshold: 80%) These fixes reduce Not Viable mutation rate from ~95% to ~12% and ensure .gomuignore patterns work in all scenarios.
715c58f to
7182e6b
Compare
Contributor
🧬 Mutation Testing Results✅ Quality Gate: PASSED Overall Mutation Score: 21.1% Files with Mutations
Generated by gomu mutation testing |
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.
Summary
.gomuignorepatterns not being applied during incremental analysis--incrementalCLI flag being ignoredChanges
.gomuignore fix
Previously, ignore patterns were only applied in
GetAllGoFiles(), butGetChangedFiles()(used during incremental analysis) did not check ignore patterns. This caused files likecmd/gomu/main.goto be processed even whencmd/was in.gomuignore.Not Viable fix
The compilation check was using
go build <file.go>which only compiles a single file. When that file depends on other files in the same package, compilation fails. Changed togo build .with overlay to properly resolve all package dependencies.Incremental flag fix
The
incrementaloption was hardcoded totrueinIncrementalAnalyzer, ignoring the CLI--incrementalflag.Results
.gomuignorepatterns now work correctly in all scenariosTest Plan
gomu run ./examples/shows improved resultscmd/directory is properly ignored