Help us shape the future of Go! Take the 2026 Go Developer Survey

grpc

package
v1.16.21 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GRPC

type GRPC struct {
	// contains filtered or unexported fields
}

GRPC is a GRPC server that can be used in integration tests.

func New

func New(t *testing.T, fopts ...Option) *GRPC

func (*GRPC) Address added in v1.13.0

func (g *GRPC) Address(t *testing.T) string

func (*GRPC) Cleanup

func (g *GRPC) Cleanup(t *testing.T)

func (*GRPC) Port

func (g *GRPC) Port(t *testing.T) int

func (*GRPC) Run

func (g *GRPC) Run(t *testing.T, ctx context.Context)

type Option

type Option func(*options)

Option is a function that configures the process.

func WithListener

func WithListener(l func() (net.Listener, error)) Option

func WithRegister

func WithRegister(f func(*grpc.Server)) Option

func WithServerOption

func WithServerOption(opt func(t *testing.T, ctx context.Context) grpc.ServerOption) Option

Directories

Path Synopsis
app

Jump to

Keyboard shortcuts

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