From 82d98c485989989ad50b0d4b5c2db38b0483aacc Mon Sep 17 00:00:00 2001 From: "Quentin McGaw (desktop)" Date: Sun, 30 May 2021 03:09:22 +0000 Subject: [PATCH] Maintenance: add more linters to .golangci.yml --- .golangci.yml | 11 +++++++---- internal/constants/servers_test.go | 2 ++ internal/provider/utils/filtering_test.go | 1 + 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index a6409d35..3bccedfb 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -37,27 +37,30 @@ linters: - godot - goheader - goimports - - golint - gomnd - goprintffuncname - gosec + # - goerr113 - gosimple - govet + - importas - ineffassign - - interfacer - lll - - maligned - misspell - nakedret - nestif + - nilerr - noctx - nolintlint - prealloc + - predeclared - rowserrcheck - - scopelint + - exportloopref - sqlclosecheck - staticcheck - structcheck + - thelper + - tparallel - typecheck - unconvert - unparam diff --git a/internal/constants/servers_test.go b/internal/constants/servers_test.go index 5c6d3deb..a3595eab 100644 --- a/internal/constants/servers_test.go +++ b/internal/constants/servers_test.go @@ -12,6 +12,7 @@ import ( ) func digestServerModelVersion(t *testing.T, server interface{}, version uint16) string { + t.Helper() bytes, err := json.Marshal(server) if err != nil { t.Fatal(err) @@ -118,6 +119,7 @@ func Test_versions(t *testing.T) { } func digestServersTimestamp(t *testing.T, servers interface{}, timestamp int64) string { + t.Helper() bytes, err := json.Marshal(servers) if err != nil { t.Fatal(err) diff --git a/internal/provider/utils/filtering_test.go b/internal/provider/utils/filtering_test.go index 9639e913..1f74cfde 100644 --- a/internal/provider/utils/filtering_test.go +++ b/internal/provider/utils/filtering_test.go @@ -28,6 +28,7 @@ func Test_FilterByPossibilities(t *testing.T) { for name, testCase := range testCases { testCase := testCase t.Run(name, func(t *testing.T) { + t.Parallel() filtered := FilterByPossibilities(testCase.value, testCase.possibilities) assert.Equal(t, testCase.filtered, filtered) })