Documentation ¶
Index ¶
- func AssertHTTPErrorCode(t *testing.T, err error, code int)
- func CreateUser(orm *ent.Client) (*ent.User, error)
- func ExecuteHandler(ctx echo.Context, handler echo.HandlerFunc, mw ...echo.MiddlewareFunc) error
- func ExecuteMiddleware(ctx echo.Context, mw echo.MiddlewareFunc) error
- func NewContext(e *echo.Echo, url string) (echo.Context, *httptest.ResponseRecorder)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertHTTPErrorCode ¶
AssertHTTPErrorCode asserts an HTTP status code on a given Echo HTTP error
func CreateUser ¶
CreateUser creates a random user entity
func ExecuteHandler ¶
func ExecuteHandler(ctx echo.Context, handler echo.HandlerFunc, mw ...echo.MiddlewareFunc) error
ExecuteHandler executes a handler with an optional stack of middleware
func ExecuteMiddleware ¶
func ExecuteMiddleware(ctx echo.Context, mw echo.MiddlewareFunc) error
ExecuteMiddleware executes a middleware function on a given Echo context
func NewContext ¶
func NewContext(e *echo.Echo, url string) (echo.Context, *httptest.ResponseRecorder)
NewContext creates a new Echo context for tests using an HTTP test request and response recorder
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.