fix: use testify instead of t.Fatal or t.Error in client package (part 1)

Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
This commit is contained in:
Matthieu MOREL
2024-11-30 13:53:50 +01:00
parent 39d9cd707a
commit 99f99cbb2f
16 changed files with 90 additions and 191 deletions

View File

@ -147,9 +147,7 @@ func TestDialTimeout(t *testing.T) {
func TestDialNoTimeout(t *testing.T) {
cfg := Config{Endpoints: []string{"127.0.0.1:12345"}}
c, err := NewClient(t, cfg)
if c == nil {
t.Fatalf("new client with DialNoWait should succeed, got %v", err)
}
require.NotNilf(t, c, "new client with DialNoWait should succeed, got %v", err)
require.NoErrorf(t, err, "new client with DialNoWait should succeed")
c.Close()
}