kusttest_test

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2019 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Harness added in v0.3.0

type Harness struct {
	// contains filtered or unexported fields
}

Harness manages a kustomize environment for tests.

func MakeHarness added in v0.3.0

func MakeHarness(t *testing.T) Harness

func MakeHarnessWithFs added in v0.3.0

func MakeHarnessWithFs(
	t *testing.T, fSys filesys.FileSystem) Harness

func (Harness) AssertActualEqualsExpected added in v0.3.0

func (th Harness) AssertActualEqualsExpected(
	m resmap.ResMap, expected string)

func (Harness) AssertActualEqualsExpectedWithTweak added in v0.3.0

func (th Harness) AssertActualEqualsExpectedWithTweak(
	m resmap.ResMap, tweaker func([]byte) []byte, expected string)

func (Harness) GetFSys added in v0.3.0

func (th Harness) GetFSys() filesys.FileSystem

func (Harness) GetT added in v0.3.0

func (th Harness) GetT() *testing.T

func (Harness) MakeDefaultOptions added in v0.3.0

func (th Harness) MakeDefaultOptions() krusty.Options

func (Harness) MakeOptionsPluginsDisabled added in v0.3.0

func (th Harness) MakeOptionsPluginsDisabled() krusty.Options

This has no impact on Builtin plugins, as they are always enabled.

func (Harness) MakeOptionsPluginsEnabled added in v0.3.0

func (th Harness) MakeOptionsPluginsEnabled() krusty.Options

Enables use of non-builtin plugins.

func (Harness) Run added in v0.3.0

func (th Harness) Run(path string, o krusty.Options) resmap.ResMap

Run, failing on error.

func (Harness) RunWithErr added in v0.3.0

func (th Harness) RunWithErr(path string, o krusty.Options) error

Run, failing if there is no error.

func (Harness) WriteF added in v0.3.0

func (th Harness) WriteF(path string, content string)

func (Harness) WriteK added in v0.3.0

func (th Harness) WriteK(path string, content string)

func (Harness) WriteLegacyConfigs added in v0.3.0

func (th Harness) WriteLegacyConfigs(fName string)

type HarnessEnhanced added in v0.3.0

type HarnessEnhanced struct {
	Harness
	// contains filtered or unexported fields
}

HarnessEnhanced manages a full plugin environment for tests.

func MakeEnhancedHarness added in v0.3.0

func MakeEnhancedHarness(t *testing.T) *HarnessEnhanced

func (*HarnessEnhanced) BuildGoPlugin added in v0.3.0

func (th *HarnessEnhanced) BuildGoPlugin(g, v, k string) *HarnessEnhanced

func (*HarnessEnhanced) ErrorFromLoadAndRunTransformer added in v0.3.0

func (th *HarnessEnhanced) ErrorFromLoadAndRunTransformer(
	config, input string) error

func (*HarnessEnhanced) LoadAndRunGenerator added in v0.3.0

func (th *HarnessEnhanced) LoadAndRunGenerator(
	config string) resmap.ResMap

func (*HarnessEnhanced) LoadAndRunTransformer added in v0.3.0

func (th *HarnessEnhanced) LoadAndRunTransformer(
	config, input string) resmap.ResMap

func (*HarnessEnhanced) PrepBuiltin added in v0.3.0

func (th *HarnessEnhanced) PrepBuiltin(k string) *HarnessEnhanced

func (*HarnessEnhanced) PrepExecPlugin added in v0.3.0

func (th *HarnessEnhanced) PrepExecPlugin(g, v, k string) *HarnessEnhanced

func (*HarnessEnhanced) Reset added in v0.3.0

func (th *HarnessEnhanced) Reset()

func (*HarnessEnhanced) ResetLoaderRoot added in v0.3.0

func (th *HarnessEnhanced) ResetLoaderRoot(root string)

func (*HarnessEnhanced) RunTransformer added in v0.3.0

func (th *HarnessEnhanced) RunTransformer(
	config, input string) (resmap.ResMap, error)

func (*HarnessEnhanced) RunTransformerFromResMap added in v0.3.0

func (th *HarnessEnhanced) RunTransformerFromResMap(
	config string, resMap resmap.ResMap) (resmap.ResMap, error)

Jump to

Keyboard shortcuts

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