Documentation ¶
Index ¶
- Constants
- func Setup(apps *Echos, cfg Config) resource.SetupFn
- func SetupSingleNamespace(view *SingleNamespaceView) resource.SetupFn
- func SetupTwoNamespaces(view *TwoNamespaceView) resource.SetupFn
- type Config
- type EchoNamespace
- type Echos
- type External
- type SingleNamespaceView
- type TwoNamespaceView
Constants ¶
View Source
const ( ASvc = "a" BSvc = "b" CSvc = "c" TproxySvc = "tproxy" VMSvc = "vm" HeadlessSvc = "headless" StatefulSetSvc = "statefulset" ProxylessGRPCSvc = "proxyless-grpc" NakedSvc = "naked" DeltaSvc = "delta" )
View Source
const (
ExternalSvc = "external"
)
Variables ¶
This section is empty.
Functions ¶
func SetupSingleNamespace ¶
func SetupSingleNamespace(view *SingleNamespaceView) resource.SetupFn
SetupSingleNamespace calls Setup and returns a SingleNamespaceView.
func SetupTwoNamespaces ¶
func SetupTwoNamespaces(view *TwoNamespaceView) resource.SetupFn
SetupTwoNamespaces calls Setup and returns a TwoNamespaceView.
Types ¶
type Config ¶
type Config struct { // Echos is the target Echos for the newly created echo apps. If nil, a new Echos // instance will be created. Echos *Echos // NamespaceCount indicates the number of echo namespaces to be generated. // Ignored if Namespaces is non-empty. Defaults to 1. NamespaceCount int // Namespaces is the user-provided list of echo namespaces. If empty, NamespaceCount // namespaces will be generated. Namespaces []namespace.Instance // NoExternalNamespace if true, no external namespace will be generated and no external echo // instance will be deployed. Ignored if ExternalNamespace is non-nil. NoExternalNamespace bool // ExternalNamespace the namespace to use for the external deployment. If nil, a namespace // will be generated unless NoExternalNamespace is specified. ExternalNamespace namespace.Instance }
Config for new echo deployment.
type EchoNamespace ¶
type EchoNamespace struct { // Namespace where the services are deployed. Namespace namespace.Instance // Standard echo app to be used by tests A echo.Instances // Standard echo app to be used by tests B echo.Instances // Standard echo app to be used by tests C echo.Instances // Standard echo app with TPROXY interception mode to be used by tests Tproxy echo.Instances // Headless echo app to be used by tests Headless echo.Instances // StatefulSet echo app to be used by tests StatefulSet echo.Instances // ProxylessGRPC echo app to be used by tests ProxylessGRPC echo.Instances // Echo app to be used by tests, with no sidecar injected Naked echo.Instances // A virtual machine echo app (only deployed to one cluster) VM echo.Instances // DeltaXDS echo app uses the delta XDS protocol. This should be functionally equivalent to A. DeltaXDS echo.Instances // All echo apps in this namespace All echo.Services }
EchoNamespace contains the echo instances for a single namespace.
type Echos ¶
type Echos struct { // NS is the list of echo namespaces. NS []EchoNamespace // External (out-of-mesh) deployments External External // All echo instances. All echo.Services }
Echos is a common set of echo deployments to support integration testing.
func (Echos) SingleNamespaceView ¶
func (d Echos) SingleNamespaceView() SingleNamespaceView
SingleNamespaceView converts this Echos into a SingleNamespaceView.
func (Echos) TwoNamespaceView ¶
func (d Echos) TwoNamespaceView() TwoNamespaceView
TwoNamespaceView converts this Echos into a TwoNamespaceView.
type SingleNamespaceView ¶
type SingleNamespaceView struct { // Include the echos at the top-level, so there is no need for accessing sub-structures. EchoNamespace // External (out-of-mesh) deployments External External // All echo instances All echo.Services }
SingleNamespaceView is a simplified view of Echos for tests that only require a single namespace.
type TwoNamespaceView ¶
type TwoNamespaceView struct { // Ns1 contains the echo deployments in the first namespace Ns1 EchoNamespace // Ns2 contains the echo deployments in the second namespace Ns2 EchoNamespace // Ns1AndNs2 contains just the echo services in Ns1 and Ns2 (excludes External). Ns1AndNs2 echo.Services // External (out-of-mesh) deployments External External // All echo instances All echo.Services }
TwoNamespaceView is a simplified view of Echos for tests that require 2 namespaces.
Click to show internal directories.
Click to hide internal directories.