Documentation ¶
Index ¶
- type Actions
- func (a *Actions) AddFile(fileName, fileContents string) *Actions
- func (a *Actions) AddSignedFile(fileName, fileContents string) *Actions
- func (a *Actions) AddSignedTag(name string) *Actions
- func (a *Actions) AddTag(name string) *Actions
- func (a *Actions) And(block func()) *Actions
- func (a *Actions) AppSet(flags ...string) *Actions
- func (a *Actions) AppUnSet(flags ...string) *Actions
- func (a *Actions) CreateApp(args ...string) *Actions
- func (a *Actions) CreateFromFile(handler func(app *Application), flags ...string) *Actions
- func (a *Actions) CreateFromPartialFile(data string, flags ...string) *Actions
- func (a *Actions) CreateMultiSourceAppFromFile(flags ...string) *Actions
- func (a *Actions) CreateWithNoNameSpace(args ...string) *Actions
- func (a *Actions) Declarative(filename string) *Actions
- func (a *Actions) DeclarativeWithCustomRepo(filename string, repoURL string) *Actions
- func (a *Actions) Delete(cascade bool) *Actions
- func (a *Actions) DeleteBySelector(selector string) *Actions
- func (a *Actions) DeleteFile(file string) *Actions
- func (a *Actions) DoNotIgnoreErrors() *Actions
- func (a *Actions) IgnoreErrors() *Actions
- func (a *Actions) PatchApp(patch string) *Actions
- func (a *Actions) PatchFile(file string, jsonPath string) *Actions
- func (a *Actions) Refresh(refreshType RefreshType) *Actions
- func (a *Actions) SetParamInSettingConfigMap(key, value string) *Actions
- func (a *Actions) SetTrackingLabel(trackingLabel string) *Actions
- func (a *Actions) SetTrackingMethod(trackingMethod string) *Actions
- func (a *Actions) Sync(args ...string) *Actions
- func (a *Actions) TerminateOp() *Actions
- func (a *Actions) Then() *Consequences
- func (a *Actions) Wait(args ...string) *Actions
- func (a *Actions) WriteFile(fileName, fileContents string) *Actions
- type Consequences
- func (c *Consequences) And(block func(app *Application)) *Consequences
- func (c *Consequences) AndAction(block func()) *Consequences
- func (c *Consequences) AndCLIOutput(block func(output string, err error)) *Consequences
- func (c *Consequences) Expect(e Expectation) *Consequences
- func (c *Consequences) Given() *Context
- func (c *Consequences) When() *Actions
- type Context
- func (c *Context) And(block func()) *Context
- func (c *Context) AppName() string
- func (c *Context) AppNamespace() string
- func (c *Context) AppQualifiedName() string
- func (c *Context) Async(async bool) *Context
- func (c *Context) Chart(chart string) *Context
- func (c *Context) ConfigManagementPlugin(plugin v1alpha1.ConfigManagementPlugin) *Context
- func (c *Context) CustomCACertAdded() *Context
- func (c *Context) CustomSSHKnownHostsAdded() *Context
- func (c *Context) DestName(destName string) *Context
- func (c *Context) DestServer(destServer string) *Context
- func (c *Context) Env(env string) *Context
- func (c *Context) Force() *Context
- func (c *Context) GPGPublicKeyAdded() *Context
- func (c *Context) GPGPublicKeyRemoved() *Context
- func (c *Context) GetName() string
- func (c *Context) GetTrackingMethod() v1alpha1.TrackingMethod
- func (c *Context) HTTPSCredentialsTLSClientCertAdded() *Context
- func (c *Context) HTTPSCredentialsUserPassAdded() *Context
- func (c *Context) HTTPSInsecureRepoURLAdded(withCreds bool) *Context
- func (c *Context) HTTPSInsecureRepoURLWithClientCertAdded() *Context
- func (c *Context) HTTPSRepoURLAdded(withCreds bool) *Context
- func (c *Context) HTTPSRepoURLWithClientCertAdded() *Context
- func (c *Context) HelmHTTPSCredentialsUserPassAdded() *Context
- func (c *Context) HelmOCIRepoAdded(name string) *Context
- func (c *Context) HelmPassCredentials() *Context
- func (c *Context) HelmRepoAdded(name string) *Context
- func (c *Context) HelmSkipCrds() *Context
- func (c *Context) HelmoOCICredentialsWithoutUserPassAdded() *Context
- func (c *Context) LocalPath(localPath string) *Context
- func (c *Context) Name(name string) *Context
- func (c *Context) NamePrefix(namePrefix string) *Context
- func (c *Context) NameSuffix(nameSuffix string) *Context
- func (c *Context) Parameter(parameter string) *Context
- func (c *Context) Path(path string) *Context
- func (c *Context) Project(project string) *Context
- func (c *Context) ProjectSpec(spec v1alpha1.AppProjectSpec) *Context
- func (c *Context) Prune(prune bool) *Context
- func (c *Context) PushChartToOCIRegistry(chartPathName, chartName, chartVersion string) *Context
- func (c *Context) Recurse() *Context
- func (c *Context) Replace() *Context
- func (c *Context) RepoURLType(urlType fixture.RepoURLType) *Context
- func (c *Context) ResourceFilter(filter settings.ResourcesFilter) *Context
- func (c *Context) ResourceOverrides(overrides map[string]v1alpha1.ResourceOverride) *Context
- func (c *Context) Revision(revision string) *Context
- func (c *Context) SSHCredentialsAdded() *Context
- func (c *Context) SSHInsecureRepoURLAdded(withCreds bool) *Context
- func (c *Context) SSHRepoURLAdded(withCreds bool) *Context
- func (c *Context) SelectedResource(resource string) *Context
- func (c *Context) SetAppNamespace(namespace string) *Context
- func (c *Context) SetTrackingMethod(trackingMethod string) *Context
- func (c *Context) Sleep(seconds time.Duration) *Context
- func (c *Context) Sources(sources []v1alpha1.ApplicationSource) *Context
- func (c *Context) SubmoduleHTTPSRepoURLAdded(withCreds bool) *Context
- func (c *Context) SubmoduleSSHRepoURLAdded(withCreds bool) *Context
- func (c *Context) Timeout(timeout int) *Context
- func (c *Context) When() *Actions
- type ContextArgs
- type Expectation
- func Condition(conditionType ApplicationConditionType, conditionMessage string) Expectation
- func DoesNotExist() Expectation
- func Error(message, err string, matchers ...func(string, string) bool) Expectation
- func ErrorRegex(messagePattern, err string) Expectation
- func Event(reason string, message string) Expectation
- func HealthIs(expected health.HealthStatusCode) Expectation
- func Namespace(name string, block func(app *Application, ns *v1.Namespace)) Expectation
- func NamespacedEvent(namespace string, reason string, message string) Expectation
- func NoConditions() Expectation
- func NoNamespace(name string) Expectation
- func NotPod(predicate func(p v1.Pod) bool) Expectation
- func OperationMessageContains(text string) Expectation
- func OperationPhaseIs(expected OperationPhase) Expectation
- func Pod(predicate func(p v1.Pod) bool) Expectation
- func ResourceHealthIs(kind, resource string, expected health.HealthStatusCode) Expectation
- func ResourceHealthWithNamespaceIs(kind, resource, namespace string, expected health.HealthStatusCode) Expectation
- func ResourceResultIs(result ResourceResult) Expectation
- func ResourceResultMatches(result ResourceResult) Expectation
- func ResourceResultNumbering(num int) Expectation
- func ResourceSyncStatusIs(kind, resource string, expected SyncStatusCode) Expectation
- func ResourceSyncStatusWithNamespaceIs(kind, resource, namespace string, expected SyncStatusCode) Expectation
- func Success(message string) Expectation
- func SyncStatusIs(expected SyncStatusCode) Expectation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Actions ¶
type Actions struct {
// contains filtered or unexported fields
}
this implements the "when" part of given/when/then
none of the func implement error checks, and that is complete intended, you should check for errors using the Then()
func (*Actions) AddSignedFile ¶
func (*Actions) AddSignedTag ¶ added in v2.5.18
func (*Actions) CreateFromFile ¶
func (*Actions) CreateFromPartialFile ¶
func (*Actions) CreateMultiSourceAppFromFile ¶ added in v2.6.0
func (*Actions) CreateWithNoNameSpace ¶
func (*Actions) Declarative ¶
func (*Actions) DeclarativeWithCustomRepo ¶
func (*Actions) DeleteBySelector ¶ added in v2.5.0
func (*Actions) DeleteFile ¶
func (*Actions) DoNotIgnoreErrors ¶
func (*Actions) IgnoreErrors ¶
func (*Actions) SetParamInSettingConfigMap ¶ added in v2.4.0
func (*Actions) SetTrackingLabel ¶ added in v2.4.6
func (*Actions) SetTrackingMethod ¶ added in v2.4.6
func (*Actions) TerminateOp ¶
func (*Actions) Then ¶
func (a *Actions) Then() *Consequences
type Consequences ¶
type Consequences struct {
// contains filtered or unexported fields
}
this implements the "then" part of given/when/then
func (*Consequences) And ¶
func (c *Consequences) And(block func(app *Application)) *Consequences
func (*Consequences) AndAction ¶ added in v2.3.0
func (c *Consequences) AndAction(block func()) *Consequences
func (*Consequences) AndCLIOutput ¶ added in v2.5.0
func (c *Consequences) AndCLIOutput(block func(output string, err error)) *Consequences
func (*Consequences) Expect ¶
func (c *Consequences) Expect(e Expectation) *Consequences
func (*Consequences) Given ¶
func (c *Consequences) Given() *Context
func (*Consequences) When ¶
func (c *Consequences) When() *Actions
type Context ¶
type Context struct {
// contains filtered or unexported fields
}
this implements the "given" part of given/when/then
func GivenWithNamespace ¶ added in v2.5.0
func GivenWithSameState ¶ added in v2.2.0
func (*Context) AppNamespace ¶ added in v2.5.0
func (*Context) AppQualifiedName ¶ added in v2.5.0
func (*Context) ConfigManagementPlugin ¶
func (c *Context) ConfigManagementPlugin(plugin v1alpha1.ConfigManagementPlugin) *Context
this both configures the plugin, but forces use of it
func (*Context) CustomCACertAdded ¶
func (*Context) CustomSSHKnownHostsAdded ¶
func (*Context) DestServer ¶
func (*Context) GPGPublicKeyAdded ¶
func (*Context) GPGPublicKeyRemoved ¶
func (*Context) GetTrackingMethod ¶ added in v2.5.0
func (c *Context) GetTrackingMethod() v1alpha1.TrackingMethod
func (*Context) HTTPSCredentialsTLSClientCertAdded ¶
func (*Context) HTTPSCredentialsUserPassAdded ¶
func (*Context) HTTPSInsecureRepoURLAdded ¶
func (*Context) HTTPSInsecureRepoURLWithClientCertAdded ¶
func (*Context) HTTPSRepoURLAdded ¶
func (*Context) HTTPSRepoURLWithClientCertAdded ¶
func (*Context) HelmHTTPSCredentialsUserPassAdded ¶ added in v2.1.2
func (*Context) HelmOCIRepoAdded ¶ added in v2.1.0
func (*Context) HelmPassCredentials ¶ added in v2.2.0
func (*Context) HelmRepoAdded ¶
func (*Context) HelmSkipCrds ¶ added in v2.3.0
func (*Context) HelmoOCICredentialsWithoutUserPassAdded ¶ added in v2.1.0
func (*Context) NamePrefix ¶
func (*Context) NameSuffix ¶
func (*Context) ProjectSpec ¶
func (c *Context) ProjectSpec(spec v1alpha1.AppProjectSpec) *Context
func (*Context) PushChartToOCIRegistry ¶ added in v2.1.0
func (*Context) RepoURLType ¶
func (c *Context) RepoURLType(urlType fixture.RepoURLType) *Context
func (*Context) ResourceFilter ¶
func (c *Context) ResourceFilter(filter settings.ResourcesFilter) *Context
func (*Context) ResourceOverrides ¶
func (c *Context) ResourceOverrides(overrides map[string]v1alpha1.ResourceOverride) *Context
func (*Context) SSHCredentialsAdded ¶
func (*Context) SSHInsecureRepoURLAdded ¶
func (*Context) SSHRepoURLAdded ¶
func (*Context) SelectedResource ¶
group:kind:name
func (*Context) SetAppNamespace ¶ added in v2.5.0
func (*Context) SetTrackingMethod ¶ added in v2.4.6
func (*Context) Sources ¶ added in v2.6.0
func (c *Context) Sources(sources []v1alpha1.ApplicationSource) *Context
func (*Context) SubmoduleHTTPSRepoURLAdded ¶
func (*Context) SubmoduleSSHRepoURLAdded ¶
type ContextArgs ¶ added in v2.5.0
type ContextArgs struct {
AppNamespace string
}
type Expectation ¶
type Expectation func(c *Consequences) (state state, message string)
func Condition ¶
func Condition(conditionType ApplicationConditionType, conditionMessage string) Expectation
func DoesNotExist ¶
func DoesNotExist() Expectation
func Error ¶
func Error(message, err string, matchers ...func(string, string) bool) Expectation
Error asserts that the last command was an error with substring match
func ErrorRegex ¶ added in v2.3.0
func ErrorRegex(messagePattern, err string) Expectation
ErrorRegex asserts that the last command was an error that matches given regex epxression
func Event ¶
func Event(reason string, message string) Expectation
func HealthIs ¶
func HealthIs(expected health.HealthStatusCode) Expectation
func Namespace ¶ added in v2.6.0
func Namespace(name string, block func(app *Application, ns *v1.Namespace)) Expectation
func NamespacedEvent ¶ added in v2.5.0
func NamespacedEvent(namespace string, reason string, message string) Expectation
func NoConditions ¶
func NoConditions() Expectation
func NoNamespace ¶ added in v2.6.0
func NoNamespace(name string) Expectation
func OperationMessageContains ¶
func OperationMessageContains(text string) Expectation
func OperationPhaseIs ¶
func OperationPhaseIs(expected OperationPhase) Expectation
func ResourceHealthIs ¶
func ResourceHealthIs(kind, resource string, expected health.HealthStatusCode) Expectation
func ResourceHealthWithNamespaceIs ¶
func ResourceHealthWithNamespaceIs(kind, resource, namespace string, expected health.HealthStatusCode) Expectation
func ResourceResultIs ¶
func ResourceResultIs(result ResourceResult) Expectation
func ResourceResultMatches ¶
func ResourceResultMatches(result ResourceResult) Expectation
func ResourceResultNumbering ¶
func ResourceResultNumbering(num int) Expectation
func ResourceSyncStatusIs ¶
func ResourceSyncStatusIs(kind, resource string, expected SyncStatusCode) Expectation
func ResourceSyncStatusWithNamespaceIs ¶
func ResourceSyncStatusWithNamespaceIs(kind, resource, namespace string, expected SyncStatusCode) Expectation
func Success ¶
func Success(message string) Expectation
asserts that the last command was successful
func SyncStatusIs ¶
func SyncStatusIs(expected SyncStatusCode) Expectation
Click to show internal directories.
Click to hide internal directories.