-
Notifications
You must be signed in to change notification settings - Fork 207
chore: Upgrades golangci-lint to v2 #3224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
} else { | ||
assert.NotNil(t, ret) | ||
assert.Equal(t, len(*value), len(*ret)) | ||
assert.Len(t, *value, len(*ret)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixes: len: use assert.Len (testifylint)
assert.Equal(t, 0, conversion.SafeValue(intPointer)) | ||
var stringPointer *string | ||
assert.Equal(t, "", conversion.SafeValue(stringPointer)) | ||
assert.Empty(t, conversion.SafeValue(stringPointer)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixes: empty: use assert.NotEmpty (testifylint)
isOpIncSet := oplogIncOk && oplogInc != nil && (oplogInc.(int) > 0) | ||
|
||
if !isPITSet && !(isOpTSSet && isOpIncSet) { | ||
if !isPITSet && (!isOpTSSet || !isOpIncSet) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixes: QF1001: could apply De Morgan's law (staticcheck)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Description
Upgrades golangci-lint to v2 using the migration guide, follow example in: mongodb/openapi#616
Link to any related issue(s):
Type of change:
Required Checklist:
Further comments