testsetting

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2023 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var KCP_BIN = os.Getenv("KCP_BIN")
View Source
var KCP_ISRUNNING = os.Getenv("KCP_ISRUNNING")
View Source
var KCP_KUBECONFIG = os.Getenv("KCP_KUBECONFIG")
View Source
var KCP_ROOTDIR = os.Getenv("KCP_ROOTDIR")

Functions

This section is empty.

Types

type KcpTestSetting

type KcpTestSetting struct {
	Cfg                       *rest.Config
	K8sClient                 client.Client
	OcmK8ResourceInterfaceSet ocmk8sclients.OcmK8ResourceInterfaceSetType
	Ctx                       context.Context
	Cancel                    context.CancelFunc
	// contains filtered or unexported fields
}

func KcpSetup

func KcpSetup(timeout time.Duration) (*KcpTestSetting, error)

func (*KcpTestSetting) CreateWorkspace

func (t *KcpTestSetting) CreateWorkspace(timeout time.Duration, interval time.Duration, wsDyClient dynamic.NamespaceableResourceInterface, unst *unstructured.Unstructured)

func (*KcpTestSetting) TerminateKcp

func (t *KcpTestSetting) TerminateKcp() error

type TestSetting

type TestSetting struct {
	Cfg                       *rest.Config
	K8sClient                 client.Client
	DyClient                  dynamic.Interface
	OcmK8ResourceInterfaceSet ocmk8sclients.OcmK8ResourceInterfaceSetType
	TestEnv                   *envtest.Environment
	Ctx                       context.Context
	Cancel                    context.CancelFunc
	Timeout                   time.Duration
	Interval                  time.Duration
	SampleNamespace           string
}

func Setup

func Setup(timout time.Duration, interval time.Duration) (*TestSetting, error)

func (*TestSetting) CreateNamespace

func (t *TestSetting) CreateNamespace(namespace string)

func (*TestSetting) CreateNamespacedObj

func (t *TestSetting) CreateNamespacedObj(namespace string, obj client.Object)

Jump to

Keyboard shortcuts

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