1
0
mirror of https://github.com/mgechev/revive.git synced 2025-11-23 22:04:49 +02:00

chore: enable thelper linter in golangci-lint (#1386)

It allows us to report errors at the right place in the tests.

There was only one function that was not using the helper.
It has been fixed to use it.
This commit is contained in:
ccoVeille
2025-05-27 07:41:11 +02:00
committed by GitHub
parent b1c9032746
commit a3338de10b
2 changed files with 3 additions and 0 deletions

View File

@@ -12,6 +12,7 @@ linters:
- misspell
- nolintlint
- revive
- thelper
- staticcheck
- unused

View File

@@ -59,6 +59,8 @@ func TestHomeConfigDir(t *testing.T) {
}
func setHome(t *testing.T, dir string) {
t.Helper()
homeEnv := "HOME"
if runtime.GOOS == "windows" {
homeEnv = "USERPROFILE"