Skip to content

Commit

Permalink
Merge pull request stretchr#96 from ac7/quote_errors
Browse files Browse the repository at this point in the history
Wrap NoError message with quote marks
  • Loading branch information
ernesto-jimenez committed Nov 1, 2015
2 parents 40b02b9 + 51cd27a commit a74f1fe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion assert/assertions.go
Original file line number Diff line number Diff line change
Expand Up @@ -801,7 +801,7 @@ func NoError(t TestingT, err error, msgAndArgs ...interface{}) bool {
return true
}

return Fail(t, fmt.Sprintf("No error is expected but got %v", err), msgAndArgs...)
return Fail(t, fmt.Sprintf("Received unexpected error %q", err), msgAndArgs...)
}

// Error asserts that a function returned an error (i.e. not `nil`).
Expand Down

0 comments on commit a74f1fe

Please sign in to comment.