(t *testing.T)
| 109 | } |
| 110 | |
| 111 | func TestToFiberHandler_ExpressTwoParamsWithoutError(t *testing.T) { |
| 112 | t.Parallel() |
| 113 | |
| 114 | app, ctx := newTestCtx(t) |
| 115 | |
| 116 | handler := func(req Req, res Res) { |
| 117 | assert.Equal(t, app, req.App()) |
| 118 | require.NoError(t, res.SendStatus(http.StatusCreated)) |
| 119 | } |
| 120 | |
| 121 | converted, ok := toFiberHandler(handler) |
| 122 | require.True(t, ok) |
| 123 | |
| 124 | require.NoError(t, converted(ctx)) |
| 125 | require.Equal(t, http.StatusCreated, ctx.Response().StatusCode()) |
| 126 | } |
| 127 | |
| 128 | func TestToFiberHandler_ExpressThreeParamsWithError(t *testing.T) { |
| 129 | t.Parallel() |
nothing calls this directly
no test coverage detected