test: expand refactoring registry coverage - #15
Closed
tomatotomata wants to merge 1 commit into
Closed
Conversation
tomatotomata
marked this pull request as ready for review
July 31, 2026 09:13
ailinter-dev
approved these changes
Jul 31, 2026
ailinter-dev
left a comment
Contributor
There was a problem hiding this comment.
Review: Approve ✅
Verified locally (CI was blocked pending approval on this fork PR):
go test -cover ./internal/refactoring/→ 85.7% coverage (issue target 80%+)- All 5 subtests pass;
go vetclean;git diff --checkclean - Additive test-only change (+78/-0), production code untouched
Non-blocking suggestions for a follow-up:
TestLookup_InputValidation"unsupported name" case usessmell: "unsupported_language"which reads like a language —unknown_smellwould be clearer.contentHint: "Guard Clauses"couples the test to strategy content; a non-empty check is more robust.
Nice work — clean table-driven coverage, matches repo patterns.
| } | ||
|
|
||
| func TestLookup_InputValidation(t *testing.T) { | ||
| tests := []struct { |
| } | ||
| } | ||
|
|
||
| func TestLookup_InputValidation(t *testing.T) { |
| t.Run(tt.name, func(t *testing.T) { | ||
| pattern := refactoring.Lookup(tt.smell) | ||
| if tt.wantNil { | ||
| if pattern != nil { |
Contributor
|
Closing as spam — not merged. Reason: this account ('tomatotomata') matches an automated mass-PR pattern:
Issue #12 remains open for genuine contributors. |
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
LookupListPatternshas a unique usable name and non-empty contentValidation
git diff --checkpassesCloses #12