Panicsf asserts that the code inside the specified PanicTestFunc panics. a.Panicsf(func(){ GoCrazy() }, "error message %s", "formatted")
(f PanicTestFunc, msg string, args ...interface{})
| 1428 | // |
| 1429 | // a.Panicsf(func(){ GoCrazy() }, "error message %s", "formatted") |
| 1430 | func (a *Assertions) Panicsf(f PanicTestFunc, msg string, args ...interface{}) bool { |
| 1431 | if h, ok := a.t.(tHelper); ok { |
| 1432 | h.Helper() |
| 1433 | } |
| 1434 | return Panicsf(a.t, f, msg, args...) |
| 1435 | } |
| 1436 | |
| 1437 | // Positive asserts that the specified element is positive |
| 1438 | // |