Documentation ¶
Index ¶
- func ContextWithBundlesResolverDisabled(ctx context.Context) context.Context
- func ContextWithClusterResolverDisabled(ctx context.Context) context.Context
- func ContextWithGitResolverDisabled(ctx context.Context) context.Context
- func ContextWithHttpResolverDisabled(ctx context.Context) context.Context
- func ContextWithHubResolverDisabled(ctx context.Context) context.Context
- func GetResolverFrameworkController(ctx context.Context, t *testing.T, d test.Data, resolver framework.Resolver, ...) (test.Assets, func())
- func RunResolverReconcileTest(ctx context.Context, t *testing.T, d test.Data, resolver framework.Resolver, ...)
- type ResolverReconcileTestModifier
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContextWithBundlesResolverDisabled ¶ added in v0.42.0
ContextWithBundlesResolverDisabled returns a context containing a Config with the enable-bundles-resolver feature flag disabled.
func ContextWithClusterResolverDisabled ¶ added in v0.42.0
ContextWithClusterResolverDisabled returns a context containing a Config with the enable-cluster-resolver feature flag disabled.
func ContextWithGitResolverDisabled ¶ added in v0.42.0
ContextWithGitResolverDisabled returns a context containing a Config with the enable-git-resolver feature flag disabled.
func ContextWithHttpResolverDisabled ¶ added in v0.54.0
ContextWithHttpResolverDisabled returns a context containing a Config with the enable-http-resolver feature flag disabled.
func ContextWithHubResolverDisabled ¶ added in v0.42.0
ContextWithHubResolverDisabled returns a context containing a Config with the enable-hub-resolver feature flag disabled.
func GetResolverFrameworkController ¶
func GetResolverFrameworkController(ctx context.Context, t *testing.T, d test.Data, resolver framework.Resolver, modifiers ...framework.ReconcilerModifier) (test.Assets, func())
GetResolverFrameworkController returns an instance of the resolver framework controller/reconciler using the given resolver, seeded with d, where d represents the state of the system (existing resources) needed for the test.
func RunResolverReconcileTest ¶
func RunResolverReconcileTest(ctx context.Context, t *testing.T, d test.Data, resolver framework.Resolver, request *v1beta1.ResolutionRequest, expectedStatus *v1beta1.ResolutionRequestStatus, expectedErr error, resolverModifiers ...ResolverReconcileTestModifier)
RunResolverReconcileTest takes data to seed clients and informers, a Resolver, a ResolutionRequest, and the expected ResolutionRequestStatus and error, both of which can be nil. It instantiates a controller for that resolver and reconciles the given request. It then checks for the expected error, if any, and compares the resulting status with the expected status.