Documentation
¶
Index ¶
- Constants
- Variables
- func EnsureWasmFiles(t *testing.T)
- func GetBazelBin() (string, error)
- func GetBazelBinOrDie() string
- func GetBazelWorkspace() (string, error)
- func GetBazelWorkspaceOrDie() string
- func GetDefaultEnvoyBin() (string, error)
- func GetDefaultEnvoyBinOrDie() string
- func HTTPGet(url string) (code int, respBody string, err error)
- func HTTPGetWithHeaders(l string, headers map[string]string) (code int, respBody string, err error)
- func HTTPPost(url string, contentType string, reqBody string) (code int, respBody string, err error)
- func HTTPTlsGet(url, rootdir string, port uint16) (code int, respBody string, err error)
- func IsPortUsed(port uint16) bool
- func IsTSanASan() bool
- func ShortLiveHTTPPost(url string, contentType string, reqBody string) (code int, respBody string, err error)
- func SkipTSan(t *testing.T)
- func SkipTSanASan(t *testing.T)
- func WaitForHTTPServer(url string) error
- func WaitForHTTPServerWithTLS(url, rootDir string, enableTLS bool, port uint16) error
- func WaitForPort(port uint16)
- type GRPCServer
- type Ports
- type TestInventory
Constants ¶
View Source
const SHA = "359dcd3a19f109c50e97517fe6b1e2676e870c4d"
Date: 2/22/2023
Variables ¶
View Source
var Modules = []string{
"attributegen",
}
Functions ¶
func EnsureWasmFiles ¶
EnsureWasmFiles downloads wasm files for testing.
func GetBazelBin ¶
func GetBazelBinOrDie ¶
func GetBazelBinOrDie() string
func GetBazelWorkspace ¶
func GetBazelWorkspaceOrDie ¶
func GetBazelWorkspaceOrDie() string
func GetDefaultEnvoyBin ¶
func GetDefaultEnvoyBinOrDie ¶
func GetDefaultEnvoyBinOrDie() string
func HTTPGetWithHeaders ¶
HTTPGetWithHeaders send HTTP with headers
func HTTPPost ¶
func HTTPPost(url string, contentType string, reqBody string) (code int, respBody string, err error)
HTTPPost sends POST
func HTTPTlsGet ¶
HTTPGet send GET
func IsTSanASan ¶
func IsTSanASan() bool
func ShortLiveHTTPPost ¶
func ShortLiveHTTPPost(url string, contentType string, reqBody string) (code int, respBody string, err error)
ShortLiveHTTPPost send HTTP without keepalive
func SkipTSanASan ¶
func WaitForHTTPServer ¶
WaitForHTTPServer waits for a HTTP server
func WaitForHTTPServerWithTLS ¶
WaitForHTTPServer waits for a HTTP server
Types ¶
type GRPCServer ¶
type GRPCServer struct { grpc_echo.UnimplementedEchoServer // contains filtered or unexported fields }
GRPCServer provides a simple grpc echo service for testing.
func NewGRPCServer ¶
func NewGRPCServer(port uint16) *GRPCServer
NewGRPCServer configures a new GRPCServer. It does not attempt to start listening or anything else, however.
func (*GRPCServer) Echo ¶
func (g *GRPCServer) Echo(ctx context.Context, req *grpc_echo.EchoRequest) (*empty.Empty, error)
Echo implements the grpc_echo service.
func (*GRPCServer) EchoStream ¶
func (g *GRPCServer) EchoStream(stream grpc_echo.Echo_EchoStreamServer) error
func (*GRPCServer) Start ¶
func (g *GRPCServer) Start() <-chan error
Start causes the GRPCServer to start a listener and begin serving.
type Ports ¶
type Ports struct { BackendPort uint16 ClientAdmin uint16 ClientPort uint16 ServerPort uint16 ServerAdmin uint16 XDSPort uint16 ServerTunnelPort uint16 Max uint16 }
Ports stores all used ports
type TestInventory ¶
type TestInventory struct {
Tests []string
}
func (*TestInventory) GetTestIndex ¶
func (p *TestInventory) GetTestIndex(t *testing.T) uint16
Click to show internal directories.
Click to hide internal directories.