MCPcopy Index your code
hub / github.com/expr-lang/expr / Panics

Method Panics

internal/testify/assert/assertion_forward.go:1374–1379  ·  view source on GitHub ↗

Panics asserts that the code inside the specified PanicTestFunc panics. a.Panics(func(){ GoCrazy() })

(f PanicTestFunc, msgAndArgs ...interface{})

Source from the content-addressed store, hash-verified

1372//
1373// a.Panics(func(){ GoCrazy() })
1374func (a *Assertions) Panics(f PanicTestFunc, msgAndArgs ...interface{}) bool {
1375 if h, ok := a.t.(tHelper); ok {
1376 h.Helper()
1377 }
1378 return Panics(a.t, f, msgAndArgs...)
1379}
1380
1381// PanicsWithError asserts that the code inside the specified PanicTestFunc
1382// panics, and that the recovered panic value is an error that satisfies the

Callers 1

TestPanicsWrapperFunction · 0.45

Calls 2

PanicsFunction · 0.70
HelperMethod · 0.45

Tested by 1

TestPanicsWrapperFunction · 0.36