Documentation ¶
Overview ¶
Package funcs contains convenience functions for working with e2e-framework
Index ¶
- Constants
- func AddBlueprintTypeToScheme() env.Func
- func AddonHaveStatusWithin(d time.Duration, addon *v1alpha1.Addon, desired v1alpha1.StatusType) features.Func
- func AllOf(fns ...features.Func) features.Func
- func ApplyHandler(r *resources.Resources, manager string) decoder.HandlerFunc
- func ApplyResources(manager, dir, pattern string, options ...decoder.DecodeOption) features.Func
- func CertificateHaveStatusWithin(d time.Duration, cert *certmanager.Certificate, ...) features.Func
- func ClusterIssuerHaveStatusWithin(d time.Duration, ci *certmanager.ClusterIssuer, ...) features.Func
- func ComponentResourcesCreatedWithin(d time.Duration, objects ...runtime.Object) features.Func
- func DeleteResource(o k8s.Object) features.Func
- func DeleteResources(dir, pattern string) features.Func
- func DeploymentBecomesAvailableWithin(d time.Duration, namespace, name string) features.Func
- func InstallBlueprintOperator(img string) env.Func
- func IssuerHaveStatusWithin(d time.Duration, issuer *certmanager.Issuer, ...) features.Func
- func ResourceDeletedWithin(d time.Duration, o k8s.Object) features.Func
- func ResourceMatchWithin(d time.Duration, o k8s.Object, matcher ResourceMatcher) features.Func
- func ResourcesCreatedWithin(d time.Duration, dir, pattern string) features.Func
- func ResourcesDeletedWithin(d time.Duration, dir, pattern string) features.Func
- func SleepFor(d time.Duration) env.FeatureFunc
- type ResourceMatcher
Constants ¶
const DefaultPollInterval = time.Millisecond * 500
DefaultPollInterval is the suggested poll interval for wait.For.
Variables ¶
This section is empty.
Functions ¶
func AddBlueprintTypeToScheme ¶
AddBlueprintTypeToScheme adds the blueprint operator's custom resources to the environment's scheme so that the environment's client can work with these types.
func AddonHaveStatusWithin ¶
func AddonHaveStatusWithin(d time.Duration, addon *v1alpha1.Addon, desired v1alpha1.StatusType) features.Func
AddonHaveStatusWithin fails a test if the supplied addon do not have (i.e. become) the supplied status within the supplied duration.
func ApplyHandler ¶
func ApplyHandler(r *resources.Resources, manager string) decoder.HandlerFunc
ApplyHandler is a decoder.Handler that uses server-side apply to apply the supplied object.
func ApplyResources ¶
func ApplyResources(manager, dir, pattern string, options ...decoder.DecodeOption) features.Func
ApplyResources applies all manifests under the supplied directory that match the supplied glob pattern (e.g. *.yaml). It uses server-side apply - fields are managed by the supplied field manager. It fails the test if any supplied resource cannot be applied successfully.
func CertificateHaveStatusWithin ¶
func CertificateHaveStatusWithin(d time.Duration, cert *certmanager.Certificate, desired certmanagermeta.ConditionStatus) features.Func
CertificateHaveStatusWithin fails a test if the supplied certificate does not have (i.e. become) the supplied status within the supplied duration.
func ClusterIssuerHaveStatusWithin ¶
func ClusterIssuerHaveStatusWithin(d time.Duration, ci *certmanager.ClusterIssuer, desired certmanagermeta.ConditionStatus) features.Func
ClusterIssuerHaveStatusWithin fails a test if the supplied cluster issuer do not have (i.e. become) the supplied status within the supplied duration.
func DeleteResource ¶
DeleteResource deletes (from the environment) the supplied resource.
func DeleteResources ¶
DeleteResources deletes (from the environment) all resources defined by the manifests under the supplied directory that match the supplied glob pattern (e.g. *.yaml).
func DeploymentBecomesAvailableWithin ¶
DeploymentBecomesAvailableWithin fails a test if the supplied Deployment is not Available within the supplied duration.
func InstallBlueprintOperator ¶
InstallBlueprintOperator installs the blueprint operator
func IssuerHaveStatusWithin ¶
func IssuerHaveStatusWithin(d time.Duration, issuer *certmanager.Issuer, desired certmanagermeta.ConditionStatus) features.Func
IssuerHaveStatusWithin fails a test if the supplied issuer do not have (i.e. become) the supplied status within the supplied duration.
func ResourceDeletedWithin ¶
ResourceDeletedWithin fails a test if the supplied resource is not deleted within the supplied duration.
func ResourceMatchWithin ¶
ResourceMatchWithin fails a test if the supplied resource does not match the supplied matcher within the supplied duration.
func ResourcesCreatedWithin ¶
ResourcesCreatedWithin fails a test if the supplied resources are not found to exist within the supplied duration.
func ResourcesDeletedWithin ¶
ResourcesDeletedWithin fails a test if the supplied resources are not deleted within the supplied duration.
Types ¶
type ResourceMatcher ¶
ResourceMatcher is a function that returns true if the supplied resource matches the desired state.