Documentation ¶
Index ¶
- func KluctlExecute(t *testing.T, ctx context.Context, logFn func(args ...any), args ...string) (string, string, error)
- type KustomizeResource
- type TestProject
- func (p *TestProject) AddDeploymentInclude(dir string, includePath string, tags []string)
- func (p *TestProject) AddDeploymentIncludes(dir string)
- func (p *TestProject) AddDeploymentItem(dir string, item *uo.UnstructuredObject)
- func (p *TestProject) AddExtraArgs(a ...string)
- func (p *TestProject) AddHelmDeployment(dir string, repoUrl string, chartName, version string, releaseName string, ...)
- func (p *TestProject) AddKustomizeDeployment(dir string, resources []KustomizeResource, tags []string)
- func (p *TestProject) AddKustomizeResources(dir string, resources []KustomizeResource)
- func (p *TestProject) CopyProjectSourceTo(dst string) string
- func (p *TestProject) DeleteFile(pth string, message string)
- func (p *TestProject) DeleteKustomizeDeployment(dir string)
- func (p *TestProject) Discriminator(targetName string) string
- func (p *TestProject) GetDeploymentYaml(dir string) *uo.UnstructuredObject
- func (p *TestProject) GetGitRepo() *git.Repository
- func (p *TestProject) GetGitWorktree() *git.Worktree
- func (p *TestProject) GetYaml(path string) *uo.UnstructuredObject
- func (p *TestProject) GitRepoName() string
- func (p *TestProject) GitServer() *git2.TestGitServer
- func (p *TestProject) GitUrl() string
- func (p *TestProject) GitUrlPath() string
- func (p *TestProject) IsUseProcess() bool
- func (p *TestProject) Kluctl(t *testing.T, argsIn ...string) (string, string, error)
- func (p *TestProject) KluctlExecute(t *testing.T, argsIn ...string) (string, string, error)
- func (p *TestProject) KluctlMust(t *testing.T, argsIn ...string) (string, string)
- func (p *TestProject) KluctlProcess(t *testing.T, argsIn ...string) (string, string, error)
- func (p *TestProject) KluctlProcessMust(t *testing.T, argsIn ...string) (string, string)
- func (p *TestProject) ListDeploymentItemPathes(dir string, fullPath bool) []string
- func (p *TestProject) LocalProjectDir() string
- func (p *TestProject) LocalWorkDir() string
- func (p *TestProject) SetEnv(k string, v string)
- func (p *TestProject) SetSkipProjectDirArg(b bool)
- func (p *TestProject) TestSlug() string
- func (p *TestProject) UpdateDeploymentItems(dir string, ...)
- func (p *TestProject) UpdateDeploymentYaml(dir string, update func(o *uo.UnstructuredObject) error)
- func (p *TestProject) UpdateFile(pth string, update func(f string) (string, error), message string)
- func (p *TestProject) UpdateKluctlYaml(update func(o *uo.UnstructuredObject) error)
- func (p *TestProject) UpdateKustomizeDeployment(dir string, update func(o *uo.UnstructuredObject, wt *git.Worktree) error)
- func (p *TestProject) UpdateNamedListItem(path uo.KeyPath, name string, cb func(item *uo.UnstructuredObject))
- func (p *TestProject) UpdateSecretSet(name string, cb func(secretSet *uo.UnstructuredObject))
- func (p *TestProject) UpdateTarget(name string, cb func(target *uo.UnstructuredObject))
- func (p *TestProject) UpdateYaml(pth string, update func(o *uo.UnstructuredObject) error, message string)
- type TestProjectOption
- func WithBareProject() TestProjectOption
- func WithGitServer(s *git2.TestGitServer) TestProjectOption
- func WithGitSubDir(subDir string) TestProjectOption
- func WithRepoName(n string) TestProjectOption
- func WithSkipProjectDirArg(b bool) TestProjectOption
- func WithUseProcess(useProcess bool) TestProjectOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type KustomizeResource ¶
type TestProject ¶
type TestProject struct {
// contains filtered or unexported fields
}
func NewTestProject ¶
func NewTestProject(t *testing.T, opts ...TestProjectOption) *TestProject
func (*TestProject) AddDeploymentInclude ¶
func (p *TestProject) AddDeploymentInclude(dir string, includePath string, tags []string)
func (*TestProject) AddDeploymentIncludes ¶
func (p *TestProject) AddDeploymentIncludes(dir string)
func (*TestProject) AddDeploymentItem ¶
func (p *TestProject) AddDeploymentItem(dir string, item *uo.UnstructuredObject)
func (*TestProject) AddExtraArgs ¶ added in v2.22.0
func (p *TestProject) AddExtraArgs(a ...string)
func (*TestProject) AddHelmDeployment ¶
func (*TestProject) AddKustomizeDeployment ¶
func (p *TestProject) AddKustomizeDeployment(dir string, resources []KustomizeResource, tags []string)
func (*TestProject) AddKustomizeResources ¶
func (p *TestProject) AddKustomizeResources(dir string, resources []KustomizeResource)
func (*TestProject) CopyProjectSourceTo ¶ added in v2.22.0
func (p *TestProject) CopyProjectSourceTo(dst string) string
func (*TestProject) DeleteFile ¶ added in v2.22.0
func (p *TestProject) DeleteFile(pth string, message string)
func (*TestProject) DeleteKustomizeDeployment ¶
func (p *TestProject) DeleteKustomizeDeployment(dir string)
func (*TestProject) Discriminator ¶
func (p *TestProject) Discriminator(targetName string) string
func (*TestProject) GetDeploymentYaml ¶
func (p *TestProject) GetDeploymentYaml(dir string) *uo.UnstructuredObject
func (*TestProject) GetGitRepo ¶
func (p *TestProject) GetGitRepo() *git.Repository
func (*TestProject) GetGitWorktree ¶
func (p *TestProject) GetGitWorktree() *git.Worktree
func (*TestProject) GetYaml ¶
func (p *TestProject) GetYaml(path string) *uo.UnstructuredObject
func (*TestProject) GitRepoName ¶
func (p *TestProject) GitRepoName() string
func (*TestProject) GitServer ¶
func (p *TestProject) GitServer() *git2.TestGitServer
func (*TestProject) GitUrl ¶
func (p *TestProject) GitUrl() string
func (*TestProject) GitUrlPath ¶ added in v2.23.0
func (p *TestProject) GitUrlPath() string
func (*TestProject) IsUseProcess ¶ added in v2.22.0
func (p *TestProject) IsUseProcess() bool
func (*TestProject) KluctlExecute ¶
func (*TestProject) KluctlMust ¶
func (*TestProject) KluctlProcess ¶
func (*TestProject) KluctlProcessMust ¶
func (*TestProject) ListDeploymentItemPathes ¶
func (p *TestProject) ListDeploymentItemPathes(dir string, fullPath bool) []string
func (*TestProject) LocalProjectDir ¶
func (p *TestProject) LocalProjectDir() string
func (*TestProject) LocalWorkDir ¶ added in v2.23.0
func (p *TestProject) LocalWorkDir() string
func (*TestProject) SetEnv ¶ added in v2.22.0
func (p *TestProject) SetEnv(k string, v string)
func (*TestProject) SetSkipProjectDirArg ¶ added in v2.22.0
func (p *TestProject) SetSkipProjectDirArg(b bool)
func (*TestProject) TestSlug ¶
func (p *TestProject) TestSlug() string
func (*TestProject) UpdateDeploymentItems ¶
func (p *TestProject) UpdateDeploymentItems(dir string, update func(items []*uo.UnstructuredObject) []*uo.UnstructuredObject)
func (*TestProject) UpdateDeploymentYaml ¶
func (p *TestProject) UpdateDeploymentYaml(dir string, update func(o *uo.UnstructuredObject) error)
func (*TestProject) UpdateFile ¶
func (*TestProject) UpdateKluctlYaml ¶
func (p *TestProject) UpdateKluctlYaml(update func(o *uo.UnstructuredObject) error)
func (*TestProject) UpdateKustomizeDeployment ¶
func (p *TestProject) UpdateKustomizeDeployment(dir string, update func(o *uo.UnstructuredObject, wt *git.Worktree) error)
func (*TestProject) UpdateNamedListItem ¶
func (p *TestProject) UpdateNamedListItem(path uo.KeyPath, name string, cb func(item *uo.UnstructuredObject))
func (*TestProject) UpdateSecretSet ¶
func (p *TestProject) UpdateSecretSet(name string, cb func(secretSet *uo.UnstructuredObject))
func (*TestProject) UpdateTarget ¶
func (p *TestProject) UpdateTarget(name string, cb func(target *uo.UnstructuredObject))
func (*TestProject) UpdateYaml ¶
func (p *TestProject) UpdateYaml(pth string, update func(o *uo.UnstructuredObject) error, message string)
type TestProjectOption ¶
type TestProjectOption func(p *TestProject)
func WithBareProject ¶
func WithBareProject() TestProjectOption
func WithGitServer ¶
func WithGitServer(s *git2.TestGitServer) TestProjectOption
func WithGitSubDir ¶
func WithGitSubDir(subDir string) TestProjectOption
func WithRepoName ¶
func WithRepoName(n string) TestProjectOption
func WithSkipProjectDirArg ¶ added in v2.22.0
func WithSkipProjectDirArg(b bool) TestProjectOption
func WithUseProcess ¶
func WithUseProcess(useProcess bool) TestProjectOption
Click to show internal directories.
Click to hide internal directories.