Use Go 1.9 t.Helper() to remove testify from the output of the tests and
stop using `\r` to try to overwrite the output.
This means in Go 1.7 and Go 1.8 testify will appear as failing the test.
HTTP assertions were missing the trailing `msgAndArgs ...interface{}`,
making it inconsistent with the rest of the assertions and resulting in
incorrect `*f` wrappers.
Fixes#528
- NoError prints the error message on the next line, unquoted, which makes multiline error messages much clearer. Sample of an error message which includes a multiline stacktrace:
Error: Received unexpected error:
Hi!
/Volumes/Pouch/Users/russegan/dev/go/src/gitlab.protectv.local/ncryptify/client.git/client_test.go:27 (0x75c8c)
TestNew: assert.NoError(merry.New("Hi!"), "with message")
/usr/local/Cellar/go/1.7rc1/libexec/src/testing/testing.go:610 (0x70a01)
tRunner: fn(t)
/usr/local/Cellar/go/1.7rc1/libexec/src/runtime/asm_amd64.s:2086 (0x5d131)
goexit: BYTE $0x90 // NOP
Messages: with message
- Error,NoError,and EqualError now don’t inline the user’s extra messages. user’s messages are printed in the “Messages:” section, as with all other assertions.
- EqualError now avoids isNil(), mirroring the changes already made to Error and NoError.
- Equal, EqualValues, and EqualError now print the expected and actual values each on a newline, aligned vertically, which makes it easier for a human to visually detect the differences. Examples:
Error: Error message not equal:
expected: ”no failure"
recieved: “failure"
Messages: with message
Error: Not equal:
"high" (expected)
"low" (actual)
Messages: with message
- EqualValues uses the same value formatting and diff output as Equal for consistency