bridgetest

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TestTargetName = "bridgetest"
	TestDialTarget = "passthrough:///bridgetest"
)

Variables

This section is empty.

Functions

func EmptyGlobalProtoRegistry

func EmptyGlobalProtoRegistry()

EmptyGlobalProtoRegistry empties the global proto registries, which is needed for testing to simulate lack of PB information in grpcbridge's global registries, as it will be during real use where proto registries are constructed on the fly for each target.

func Logger

func Logger(t *testing.T) bridgelog.Logger

func MustGRPCServer

func MustGRPCServer(tb testing.TB, prepareFuncs ...func(*grpc.Server)) (*grpc.Server, *grpcadapter.AdaptedClientPool, grpcadapter.ClientConn)

func StatusCodeIs

func StatusCodeIs(err error, wantCode codes.Code) error

StatusCodeIs checks that the error has the specified gRPC status code.

func StatusIs

func StatusIs(err error, wantStatus *status.Status) error

StatusIs checks that the error matches the specified gRPC status.

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