Documentation ¶
Index ¶
Constants ¶
View Source
const ( // AppProtocolHTTP calls the app with HTTP AppProtocolHTTP = "http" // AppProtocolGRPC calls the app with GRPC AppProtocolGRPC = "grpc" // AppProtocolWebSocket calls the app with WebSocket AppProtocolWebSocket = "ws" )
Variables ¶
This section is empty.
Functions ¶
func ConstructDiscoveryRequest ¶
func ConstructDiscoveryRequest(a App, typeURL string) *xdsapi.DiscoveryRequest
ConstructDiscoveryRequest returns an Envoy discovery request.
Types ¶
type App ¶
type App interface { Name() string Endpoints() []AppEndpoint EndpointsForProtocol(protocol model.Protocol) []AppEndpoint Call(e AppEndpoint, opts AppCallOptions) ([]*echo.ParsedResponse, error) CallOrFail(e AppEndpoint, opts AppCallOptions, t testing.TB) []*echo.ParsedResponse }
App represents a deployed App within the mesh.
type AppCallOptions ¶
type AppCallOptions struct { // Protocol indicates the protocol to be used. Protocol AppProtocol // Count indicates the number of exchanges that should be made with the service endpoint. If not set (i.e. 0), defaults to 1. Count int // Headers indicates headers that should be sent in the request. Ingnored for WebSocket calls. Headers http.Header // Secure indicates whether a secure connection should be established to the endpoint. Secure bool // UseShortHostname indicates whether shortened hostnames should be used. This may be ignored by the environment. UseShortHostname bool // Path indicates the path of a REST request. Path string }
AppCallOptions defines options for calling a DeployedAppEndpoint.
type AppEndpoint ¶
type AppEndpoint interface { Name() string Owner() App Protocol() model.Protocol NetworkEndpoint() model.NetworkEndpoint }
AppEndpoint represents a single endpoint in a DeployedApp.
type AppProtocol ¶
type AppProtocol string
AppProtocol enumerates the protocol options for calling an DeployedAppEndpoint endpoint.
type Config ¶
type Config struct { Namespace namespace.Instance Pilot pilot.Instance Galley galley.Instance // AppParams specifies the apps needed for the test. If unspecified, a default suite of test apps // will be deployed. AppParams []AppParam }
Config for Apps
type Instance ¶
type Instance interface { resource.Resource Namespace() namespace.Instance GetApp(name string) (App, error) GetAppOrFail(name string, t testing.TB) App }
Instance is a component that provides access to all deployed test services.
type KubeApp ¶
type KubeApp interface { App EndpointForPort(port int) AppEndpoint }
Represents a deployed App in k8s environment.
Click to show internal directories.
Click to hide internal directories.