Errorf asserts that a function returned an error (i.e. not `nil`). actualObj, err := SomeFunction() a.Errorf(err, "error message %s", "formatted")
(err error, msg string, args ...interface{})
| 316 | // actualObj, err := SomeFunction() |
| 317 | // a.Errorf(err, "error message %s", "formatted") |
| 318 | func (a *Assertions) Errorf(err error, msg string, args ...interface{}) bool { |
| 319 | if h, ok := a.t.(tHelper); ok { |
| 320 | h.Helper() |
| 321 | } |
| 322 | return Errorf(a.t, err, msg, args...) |
| 323 | } |
| 324 | |
| 325 | // Eventually asserts that given condition will be met in waitFor time, |
| 326 | // periodically checking target function each tick. |