Skip to content

Set goconst to ignore test files#13

Merged
andrew merged 1 commit into
mainfrom
goconst-ignore-tests
May 22, 2026
Merged

Set goconst to ignore test files#13
andrew merged 1 commit into
mainfrom
goconst-ignore-tests

Conversation

@andrew
Copy link
Copy Markdown
Contributor

@andrew andrew commented May 22, 2026

Path exclusions only filter where goconst issues are reported, not which files contribute to the occurrence count, so a string used once in production code and twice in tests still gets flagged. The ignore-tests setting makes goconst skip test files entirely.

Path exclusions only filter where goconst issues are reported, not which files contribute to the occurrence count, so a string used once in production code and twice in tests still gets flagged. The `ignore-tests` setting makes goconst skip test files entirely.
@andrew andrew merged commit 5df8177 into main May 22, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant