reproxytest

package
v0.0.0-...-9febfc8 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2025 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Overview

Package reproxytest provides fake implementation of reproxy for test.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Fake

type Fake struct {
	ppb.UnimplementedCommandsServer

	RunCommandFunc func(context.Context, *ppb.RunRequest) (*ppb.RunResponse, error)
}

Fake is fake reproxy server.

func (Fake) RunCommand

func (f Fake) RunCommand(ctx context.Context, req *ppb.RunRequest) (*ppb.RunResponse, error)

RunCommand runs command on fake reproxy.

type Server

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

Server is fake reproxy grpc server.

func NewServer

func NewServer(ctx context.Context, t *testing.T, fake *Fake) *Server

NewServer starts new fake reproxy grpc server.

func (*Server) Addr

func (s *Server) Addr() string

Addr returns address of fake reproxy server to connect to.

func (*Server) Close

func (s *Server) Close()

Close closes the server.

Jump to

Keyboard shortcuts

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