orlangure/gnomock

Configure golangci-lint to skip some linters in test files

Closed this issue · 2 comments

Right now, there is a bunch of // nolint:funlen or // nolint:bodyclose comments in various tests. These comments tell golangci-lint to exclude the marked tests from linter reports.

Instead of marking each test file separately, there is a configuration of golangci-lint that we can set once in .golangci-lint.yaml. This configuration should apply to all test files.

Linters that should be disabled for test files:

  • bodyclose
  • funlen
  • gosec

@orlangure
Hi, Can I work on this issue?

Hi @u5surf,
Sure, thank you!