grpc

package
v0.0.0-...-7b34d14 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockClientStream

type MockClientStream struct {
	Ctx    context.Context
	SentCh chan *v2.DiscoveryRequest
	RecvCh chan *v2.DiscoveryResponse
	grpc.ClientStream
}

func MakeMockClientStream

func MakeMockClientStream() *MockClientStream

func (*MockClientStream) CloseSend

func (stream *MockClientStream) CloseSend() error

func (*MockClientStream) Context

func (stream *MockClientStream) Context() context.Context

func (*MockClientStream) Recv

func (stream *MockClientStream) Recv() (*v2.DiscoveryResponse, error)

func (*MockClientStream) Send

func (stream *MockClientStream) Send(resp *v2.DiscoveryRequest) error

type MockServerStream

type MockServerStream struct {
	Ctx    context.Context
	RecvCh chan *v2.DiscoveryRequest
	SentCh chan *v2.DiscoveryResponse
	Nonce  int
	grpc.ServerStream
}

func MakeMockStream

func MakeMockStream() *MockServerStream

func (*MockServerStream) ClientStream

func (stream *MockServerStream) ClientStream(stopCh chan struct{}) *MockClientStream

func (*MockServerStream) Context

func (stream *MockServerStream) Context() context.Context

func (*MockServerStream) Recv

func (stream *MockServerStream) Recv() (*v2.DiscoveryRequest, error)

func (*MockServerStream) Send

func (stream *MockServerStream) Send(resp *v2.DiscoveryResponse) error

Jump to

Keyboard shortcuts

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