Skip to content

Commit

Permalink
fix the linenumber for Equal errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ldemailly committed Feb 12, 2023
1 parent 3ad4fd5 commit c07326c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion assert.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ func EqualValues(t *testing.T, a, b interface{}, msg ...string) {

// Equal also checks for a equal b.
func Equal(t *testing.T, a, b interface{}, msg ...string) {
EqualValues(t, a, b, msg...)
if !ObjectsAreEqualValues(a, b) {
Errorf(t, "%v unexpectedly not equal %v: %v", a, b, msg)
}
}

// NoError checks for no errors (nil).
Expand Down

0 comments on commit c07326c

Please sign in to comment.