TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() — fiber Function Reference
Architecture documentation for the TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() function in adapter_test.go from the fiber codebase.
Entity Profile
Dependency Diagram
graph TD 75e6aee8_e16e_abff_282f_3ad6354f7eb4["TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError()"] 3ad7a4ef_7f07_008c_234d_52c9a342aa98["adapter_test.go"] 75e6aee8_e16e_abff_282f_3ad6354f7eb4 -->|defined in| 3ad7a4ef_7f07_008c_234d_52c9a342aa98 3776f9ef_b978_a0be_2199_412bb0eee3ec["newTestCtx()"] 75e6aee8_e16e_abff_282f_3ad6354f7eb4 -->|calls| 3776f9ef_b978_a0be_2199_412bb0eee3ec 0ba29dbe_6ac4_3e52_572c_88fd521daa4b["withRouteHandlers()"] 75e6aee8_e16e_abff_282f_3ad6354f7eb4 -->|calls| 0ba29dbe_6ac4_3e52_572c_88fd521daa4b style 75e6aee8_e16e_abff_282f_3ad6354f7eb4 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
adapter_test.go lines 264–290
func TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError(t *testing.T) {
t.Parallel()
app, ctx := newTestCtx(t)
handler := func(req Req, res Res, next func(error)) error {
assert.Equal(t, app, req.App())
assert.Equal(t, app, res.App())
next(errors.New("next error"))
return nil
}
converted, ok := toFiberHandler(handler)
require.True(t, ok)
nextCalled := false
nextHandler := func(_ Ctx) error {
nextCalled = true
return nil
}
withRouteHandlers(t, ctx, converted, nextHandler)
err := converted(ctx)
require.EqualError(t, err, "next error")
require.False(t, nextCalled)
}
Domain
Subdomains
Defined In
Source
Frequently Asked Questions
What does TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() do?
TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() is a function in the fiber codebase, defined in adapter_test.go.
Where is TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() defined?
TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() is defined in adapter_test.go at line 264.
What does TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() call?
TestToFiberHandler_ExpressNextWithErrorReturn_ShortCircuitsOnNextError() calls 2 function(s): newTestCtx, withRouteHandlers.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free