lib

package
v1.6.1 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateClient added in v0.16.0

func CreateClient(protocol string, config interface{}) types.MockClient

func CreateServer added in v0.16.0

func CreateServer(protocol string, config interface{}) types.MockServer

func InitMosn added in v0.16.0

func InitMosn(mosnConfigStr string, srvConfigs ...*Config) (m *mosn.MosnOperator, servers []types.MockServer)

InitMosn simplify MOSN test case with test framework Most cases can use the functions instead of `Setup` and `TearDown` This function also needs to be called in framework.Scenario

func RegisterCreateClient added in v0.16.0

func RegisterCreateClient(protocol string, f CreateMockClient)

func RegisterCreateServer added in v0.16.0

func RegisterCreateServer(protocol string, f CreateMockServer)

Types

type Config added in v0.16.0

type Config struct {
	Protocol string      `json:"protocol"`
	Config   interface{} `json:"config"`
}

func CreateConfig added in v0.16.0

func CreateConfig(str string) *Config

CreateConfig translate config string to Config

type CreateMockClient added in v0.16.0

type CreateMockClient func(config interface{}) types.MockClient

type CreateMockServer added in v0.16.0

type CreateMockServer func(config interface{}) types.MockServer

Directories

Path Synopsis
xprotocol

Jump to

Keyboard shortcuts

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