test(linters): Enable `testifylint`: `formatter`, `suite-broken-parallel` and `suite-subtest-run` (#15797)
This commit is contained in:
parent
2e00753df7
commit
88bca70dfd
|
|
@ -304,12 +304,15 @@ linters-settings:
|
|||
- error-nil
|
||||
- expected-actual
|
||||
- float-compare
|
||||
- formatter
|
||||
- len
|
||||
- negative-positive
|
||||
- nil-compare
|
||||
- require-error
|
||||
- suite-broken-parallel
|
||||
- suite-dont-use-pkg
|
||||
- suite-extra-assert-call
|
||||
- suite-subtest-run
|
||||
- suite-thelper
|
||||
- useless-assert
|
||||
|
||||
|
|
|
|||
|
|
@ -26,8 +26,8 @@ func toBoolPtr(b bool) *bool {
|
|||
|
||||
func TestNewClient(t *testing.T) {
|
||||
_, err := newClient("https://127.0.0.1:443/", "default", "", "abc123", time.Second, tls.ClientConfig{})
|
||||
require.NoErrorf(t, err, "Failed to create new client - %v", err)
|
||||
require.NoErrorf(t, err, "Failed to create new client: %v", err)
|
||||
|
||||
_, err = newClient("https://127.0.0.1:443/", "default", "nonexistantFile", "", time.Second, tls.ClientConfig{})
|
||||
require.Errorf(t, err, "failed to read token file \"file\": open file: no such file or directory", err)
|
||||
require.Errorf(t, err, "Failed to read token file \"file\": open file: no such file or directory: %v", err)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ func TestPathNonExistent(t *testing.T) {
|
|||
ID: "non_existent_path_test",
|
||||
Path: "non/existent/path",
|
||||
}
|
||||
require.ErrorContainsf(t, plugin.Init(), "accessing directory", "accessing directory %q failed: %w", plugin.Path, plugin.Init())
|
||||
require.ErrorContainsf(t, plugin.Init(), "accessing directory", "accessing directory %q failed: %v", plugin.Path, plugin.Init())
|
||||
}
|
||||
|
||||
func TestSetNotAvailable(t *testing.T) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue