MCPcopy
hub / github.com/stretchr/testify / Negativef

Function Negativef

require/require.go:1300–1308  ·  view source on GitHub ↗

Negativef asserts that the specified element is negative require.Negativef(t, -1, "error message %s", "formatted") require.Negativef(t, -1.23, "error message %s", "formatted")

(t TestingT, e interface{}, msg string, args ...interface{})

Source from the content-addressed store, hash-verified

1298// require.Negativef(t, -1, "error message %s", "formatted")
1299// require.Negativef(t, -1.23, "error message %s", "formatted")
1300func Negativef(t TestingT, e interface{}, msg string, args ...interface{}) {
1301 if h, ok := t.(tHelper); ok {
1302 h.Helper()
1303 }
1304 if assert.Negativef(t, e, msg, args...) {
1305 return
1306 }
1307 t.FailNow()
1308}
1309
1310// Never asserts that the given condition doesn't satisfy in waitFor time,
1311// periodically checking the target function each tick.

Callers 1

NegativefMethod · 0.70

Calls 3

NegativefFunction · 0.92
HelperMethod · 0.65
FailNowMethod · 0.65

Tested by

no test coverage detected