Skip to content

Commit

Permalink
chore: remove direct dependency on gotest.tools/v3 (#504)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandear authored Jun 13, 2024
1 parent d09b097 commit 84015fd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions docker/types/filters/parse_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"errors"
"testing"

"gotest.tools/v3/assert"
is "gotest.tools/v3/assert/cmp"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)

func TestParseArgs(t *testing.T) {
Expand All @@ -25,10 +25,10 @@ func TestParseArgs(t *testing.T) {

for i := range flagArgs {
args, err = ParseFlag(flagArgs[i], args)
assert.NilError(t, err)
require.NoError(t, err)
}
assert.Check(t, is.Len(args.Get("created"), 1))
assert.Check(t, is.Len(args.Get("image.name"), 2))
assert.Len(t, args.Get("created"), 1)
assert.Len(t, args.Get("image.name"), 2)
}

func TestParseArgsEdgeCase(t *testing.T) {
Expand Down Expand Up @@ -234,7 +234,7 @@ func TestArgsMatch(t *testing.T) {
}

for args, field := range matches {
assert.Check(t, args.Match(field, source),
assert.Truef(t, args.Match(field, source),
"Expected field %s to match %s", field, source)
}

Expand All @@ -258,7 +258,7 @@ func TestArgsMatch(t *testing.T) {
}

for args, field := range differs {
assert.Check(t, !args.Match(field, source), "Expected field %s to not match %s", field, source)
assert.Falsef(t, args.Match(field, source), "Expected field %s to not match %s", field, source)
}
}

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ require (
github.com/sirupsen/logrus v1.9.3
github.com/stretchr/testify v1.9.0
golang.org/x/sys v0.21.0
gotest.tools/v3 v3.5.1
)

require (
Expand All @@ -39,4 +38,5 @@ require (
github.com/xeipuuv/gojsonschema v1.2.0 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
gotest.tools/v3 v3.5.1 // indirect
)

0 comments on commit 84015fd

Please sign in to comment.