support

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2023 License: Apache-2.0 Imports: 35 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TestTimeoutMini   = 5 * time.Second
	TestTimeoutShort  = 1 * time.Minute
	TestTimeoutMedium = 2 * time.Minute
	TestTimeoutLong   = 5 * time.Minute
)

Variables

This section is empty.

Functions

func CatalogSource

func CatalogSource(t Test, name string, namespace string) func(g gomega.Gomega) (*olmV1Alpha1.CatalogSource, error)

func ConditionReason

func ConditionReason[T conditions.GenericConditionType](conditionType T) func(any) string

func ConditionStatus

func ConditionStatus[T conditions.GenericConditionType](conditionType T) func(any) corev1.ConditionStatus

func ControlPlane

func ControlPlane(t Test, dapr *daprApi.DaprControlPlane) func(g gomega.Gomega) (*daprApi.DaprControlPlane, error)

func Deployment

func Deployment(t Test, name string, namespace string) func(g gomega.Gomega) (*appsv1.Deployment, error)

func ExtractCatalogState

func ExtractCatalogState() func(*olmV1Alpha1.CatalogSource) string

func ExtractFirstLoadBalancerIngressHostname

func ExtractFirstLoadBalancerIngressHostname() func(*netv1.Ingress) string

func ExtractSubscriptionInstallPlan

func ExtractSubscriptionInstallPlan() func(*olmV1Alpha1.Subscription) string

func Ingress

func Ingress(t Test, name string, namespace string) func(g gomega.Gomega) (*netv1.Ingress, error)

func Pod

func Pod(t Test, name string, namespace string) func(g gomega.Gomega) (*corev1.Pod, error)

func Service

func Service(t Test, name string, namespace string) func(g gomega.Gomega) (*corev1.Service, error)

func Subscription

func Subscription(t Test, name string, namespace string) func(g gomega.Gomega) (*olmV1Alpha1.Subscription, error)

Types

type Client

type Client struct {
	kubernetes.Interface

	Dapr      daprClient.Interface
	Discovery discovery.DiscoveryInterface
	OLM       olmAC.Interface
	Helm      *helm.Helm
	// contains filtered or unexported fields
}

type Option

type Option[T any] interface {
	// contains filtered or unexported methods
}

type T

type T struct {
	*gomega.WithT
	// contains filtered or unexported fields
}

func (*T) Client

func (t *T) Client() *Client

func (*T) Ctx

func (t *T) Ctx() context.Context

func (*T) Forward

func (t *T) Forward(service string, namespace string, remotePort int) (*forwarder.Result, [][]portforward.ForwardedPort, error)

func (*T) GET

func (t *T) GET(url string) func(g gomega.Gomega) (*http.Response, error)

func (*T) HTTPClient added in v0.0.4

func (t *T) HTTPClient() *http.Client

func (*T) InstallChart

func (t *T) InstallChart(
	chart string,
	options ...helm.InstallOption,
)

func (*T) NewTestNamespace

func (t *T) NewTestNamespace(options ...Option[*corev1.Namespace]) *corev1.Namespace

func (*T) POST

func (t *T) POST(url string, contentType string, content []byte) func(g gomega.Gomega) (*http.Response, error)

func (*T) SetUpIngress

func (t *T) SetUpIngress(
	namespace string,
	path netv1.HTTPIngressPath,
) *netv1.Ingress

func (*T) T

func (t *T) T() *testing.T

type Test

func With

func With(t *testing.T) Test

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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