inproc

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package inproc serves an http.Handler in this process, without a network: the response streams through a pipe as the handler writes it. Package dotest delivers requests to objects with it, and package cloudflare serves the Worker's requests with it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Serve

func Serve(ctx context.Context, h http.Handler, req *http.Request) *http.Response

Serve runs h on req and returns its response once the handler set its status. The handler's request ends when ctx does or when the caller closes the body; once ctx ends, a read of the body is ctx's cause.

Types

This section is empty.

Jump to

Keyboard shortcuts

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