kubetest

package
v0.11.0-rc3 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KubectlOutput

type KubectlOutput struct {
	Output string
	Err    error
}

type MockKubectlCmd

type MockKubectlCmd struct {
	APIResources []*v1.APIResourceList
	Resources    []*unstructured.Unstructured
	Commands     map[string]KubectlOutput
	Events       chan watch.Event
}

func (MockKubectlCmd) ApplyResource

func (k MockKubectlCmd) ApplyResource(config *rest.Config, obj *unstructured.Unstructured, namespace string, dryRun, force bool) (string, error)

func (MockKubectlCmd) ConvertToVersion

func (k MockKubectlCmd) ConvertToVersion(obj *unstructured.Unstructured, group, version string) (*unstructured.Unstructured, error)

ConvertToVersion converts an unstructured object into the specified group/version

func (MockKubectlCmd) DeleteResource

func (k MockKubectlCmd) DeleteResource(config *rest.Config, gvk schema.GroupVersionKind, name string, namespace string, forceDelete bool) error

func (MockKubectlCmd) GetAPIResources

func (k MockKubectlCmd) GetAPIResources(config *rest.Config) ([]*v1.APIResourceList, error)

func (MockKubectlCmd) GetResource

func (k MockKubectlCmd) GetResource(config *rest.Config, gvk schema.GroupVersionKind, name string, namespace string) (*unstructured.Unstructured, error)

func (MockKubectlCmd) GetResources

func (k MockKubectlCmd) GetResources(config *rest.Config, namespace string) ([]*unstructured.Unstructured, error)

func (MockKubectlCmd) WatchResources

func (k MockKubectlCmd) WatchResources(
	ctx context.Context, config *rest.Config, namespace string) (chan watch.Event, error)

Jump to

Keyboard shortcuts

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