devserver

package
v0.2.0 Latest Latest
Warning

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

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

Documentation

Overview

Package devserver composes the synthetic, loopback-only development server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	Content       bool
	ContentOrigin string
	Reset         bool
	// Faults lets a client ask this synthetic server to lose a response after
	// committing, throttle, or disconnect mid-response. It does nothing unless
	// the binary was built with the devfaults tag, so a release build cannot
	// be talked into faulting.
	Faults bool
}

type Runtime

type Runtime struct {
	Handler   http.Handler
	TokenPath string
	// contains filtered or unexported fields
}

func Open

func Open(ctx context.Context, directory string) (*Runtime, error)

func OpenWithOptions

func OpenWithOptions(ctx context.Context, directory string, options Options) (result *Runtime, err error)

func (*Runtime) Close

func (r *Runtime) Close() error

Jump to

Keyboard shortcuts

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