From a49a161e19d638394e502da79ff77fd50f6c5e60 Mon Sep 17 00:00:00 2001 From: Matthieu MOREL Date: Thu, 25 Jan 2024 10:08:09 +0100 Subject: [PATCH] testifylint: enable compares rule Signed-off-by: Matthieu MOREL --- .golangci.yml | 2 +- docker_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 8adf7e6b0e..37f3bdc262 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -26,11 +26,11 @@ linters-settings: - prefix(github.com/testcontainers) testifylint: disable: - - compares - float-compare - go-require enable: - bool-compare + - compares - empty - error-is-as - error-nil diff --git a/docker_test.go b/docker_test.go index 1f4207944b..32c363aac1 100644 --- a/docker_test.go +++ b/docker_test.go @@ -1537,7 +1537,7 @@ func TestDockerCreateContainerWithDirs(t *testing.T) { }) terminateContainerOnEnd(t, ctx, nginxC) - require.True(t, (err != nil) == tc.hasError) + require.Equal(t, (err != nil), tc.hasError) if err == nil { dir := tc.dir