httptest

package
v1.8.1-0...-100120b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 1, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package httptest provides utilities for (fast-)HTTP testing.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HandleFast

func HandleFast(
	t *testing.T,
	handler fasthttp.RequestHandler,
	method string,
	url string,
	body io.Reader,
	check func(status int, body string, _ http.Header),
)

HandleFast serves http request using provided fasthttp handler.

func HandleFastRequest

func HandleFastRequest(
	t *testing.T,
	handler fasthttp.RequestHandler,
	req *http.Request,
	check func(status int, body string, _ http.Header),
)

HandleFastRequest serves http request using provided fasthttp handler and HTTP request.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL