mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-12-25 15:55:18 +00:00
chore(lint): Disable funlen for test functions (#1993)
This adds a regular expression that matches `func Test...` or `func (suite *Suite) Test...` style functions and disables the length check. An example from e2e tests that failed lint: `func (suite *IntegrationTestSuite) TestEip712BasicMessageAuthorization()`
This commit is contained in:
parent
edf2935f31
commit
ab10ce628c
@ -81,6 +81,13 @@ linters:
|
|||||||
# - whitespace
|
# - whitespace
|
||||||
- wrapcheck
|
- wrapcheck
|
||||||
|
|
||||||
|
issues:
|
||||||
|
exclude-rules:
|
||||||
|
# Disable funlen for "func Test..." or func (suite *Suite) Test..." type functions
|
||||||
|
# These functions tend to be descriptive and exceed length limits.
|
||||||
|
- source: "^func (\\(.*\\) )?Test"
|
||||||
|
linters:
|
||||||
|
- funlen
|
||||||
|
|
||||||
linters-settings:
|
linters-settings:
|
||||||
errcheck:
|
errcheck:
|
||||||
|
Loading…
Reference in New Issue
Block a user