Skip to content

Commit

Permalink
Pass error message to assertion library
Browse files Browse the repository at this point in the history
  • Loading branch information
Stein Fletcher committed Aug 11, 2019
1 parent 56585c6 commit 9819a0e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.PHONY: test test-examples docs fmt vet

test:
go test ./... -v -race -covermode=atomic -coverprofile=coverage.out
go test ./... -v -covermode=atomic -coverprofile=coverage.out

test-examples:
cd examples && go test -v ./... && \
Expand Down
6 changes: 3 additions & 3 deletions assert.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,17 @@ type testifyVerifier struct{}

// JSONEq asserts that two JSON strings are equivalent
func (a testifyVerifier) JSONEq(t *testing.T, expected string, actual string, msgAndArgs ...interface{}) bool {
return assert.JSONEq(t, expected, actual, msgAndArgs)
return assert.JSONEq(t, expected, actual, msgAndArgs...)
}

// Equal asserts that two objects are equal
func (a testifyVerifier) Equal(t *testing.T, expected, actual interface{}, msgAndArgs ...interface{}) bool {
return assert.Equal(t, expected, actual, msgAndArgs)
return assert.Equal(t, expected, actual, msgAndArgs...)
}

// Fail reports a failure
func (a testifyVerifier) Fail(t *testing.T, failureMessage string, msgAndArgs ...interface{}) bool {
return assert.Fail(t, failureMessage, msgAndArgs)
return assert.Fail(t, failureMessage, msgAndArgs...)
}

func newTestifyVerifier() Verifier {
Expand Down

0 comments on commit 9819a0e

Please sign in to comment.