PanicsWithErrorf asserts that the code inside the specified PanicTestFunc panics, and that the recovered panic value is an error that satisfies the EqualError comparison. a.PanicsWithErrorf("crazy error", func(){ GoCrazy() }, "error message %s", "formatted")
(errString string, f PanicTestFunc, msg string, args ...interface{})
| 1490 | // |
| 1491 | // a.PanicsWithErrorf("crazy error", func(){ GoCrazy() }, "error message %s", "formatted") |
| 1492 | func (a *Assertions) PanicsWithErrorf(errString string, f PanicTestFunc, msg string, args ...interface{}) bool { |
| 1493 | if h, ok := a.t.(tHelper); ok { |
| 1494 | h.Helper() |
| 1495 | } |
| 1496 | return PanicsWithErrorf(a.t, errString, f, msg, args...) |
| 1497 | } |
| 1498 | |
| 1499 | // PanicsWithValue asserts that the code inside the specified PanicTestFunc panics, and that |
| 1500 | // the recovered panic value equals the expected panic value. |
nothing calls this directly
no test coverage detected