Updated client_test to solve lint error (#900)
* updated client_test to solve lint error * modified golangci yml to solve linter issues * minor change
This commit is contained in:
@@ -513,8 +513,14 @@ func TestClient_suffixWithAPIVersion(t *testing.T) {
|
||||
}
|
||||
defer func() {
|
||||
if r := recover(); r != nil {
|
||||
if r.(string) != tt.wantPanic {
|
||||
t.Errorf("suffixWithAPIVersion() = %v, want %v", r, tt.wantPanic)
|
||||
// Check if the panic message matches the expected panic message
|
||||
if rStr, ok := r.(string); ok {
|
||||
if rStr != tt.wantPanic {
|
||||
t.Errorf("suffixWithAPIVersion() = %v, want %v", rStr, tt.wantPanic)
|
||||
}
|
||||
} else {
|
||||
// If the panic is not a string, log it
|
||||
t.Errorf("suffixWithAPIVersion() panicked with non-string value: %v", r)
|
||||
}
|
||||
}
|
||||
}()
|
||||
|
||||
Reference in New Issue
Block a user