From 841a3a34bc9d58c45309abaf6471a98f057af216 Mon Sep 17 00:00:00 2001 From: Panagiotis Georgiadis Date: Wed, 24 Mar 2021 15:00:54 +0100 Subject: [PATCH] Update golangci * Replace 'maligned' with 'fieldalignment' [1] * Remove 'interfacer' [2] * Enable linting against go test files as well * Disable 'funlen' linter for go table-driven tests [1] https://github.com/golangci/golangci-lint/pull/1765 [2] https://github.com/golangci/golangci-lint/issues/541 --- .golangci.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index bb4b23fa2..6386c316f 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -57,9 +57,8 @@ linters: - gosimple - govet - ineffassign - - interfacer - lll - - maligned + - fieldalignment - misspell - nakedret - prealloc @@ -78,11 +77,18 @@ linters: run: timeout: 5m + tests: true skip-dirs: - .github - build - web issues: + exclude-rules: + - linters: + - funlen + # Disable 'funlen' linter for test functions. + # It's common for table-driven tests to be more than 60 characters long + source: "^func Test" max-same-issues: 0 exclude-use-default: false