rpctest

package
v0.0.0-...-0bbbf19 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dial

func Dial(t testing.TB, network, address string) *rpc.Client

Dial connects to an RPC server at the specified network address.

func DialHTTP

func DialHTTP(t testing.TB, network, address string) *rpc.Client

DialHTTP connects to an HTTP RPC server at the specified network address listening on the default HTTP RPC path.

func DialHTTPPath

func DialHTTPPath(t testing.TB, network, address, path string) *rpc.Client

DialHTTPPath connects to an HTTP RPC server at the specified network address and path.

func Register

func Register(t testing.TB, rcvr any)

Register publishes the receiver's methods in the [DefaultServer].

func RegisterName

func RegisterName(t testing.TB, name string, rcvr any)

RegisterName is like Register but uses the provided name for the type instead of the receiver's concrete type.

func ServeRequest

func ServeRequest(t testing.TB, codec rpc.ServerCodec)

ServeRequest is like [ServeCodec] but synchronously serves a single request. It does not close the codec upon completion.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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