framework

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2020 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RemoveCleanupAction

func RemoveCleanupAction(p CleanupActionHandle)

RemoveCleanupAction removes a function that was installed by AddCleanupAction.

func RunCleanupActions

func RunCleanupActions()

RunCleanupActions runs all functions installed by AddCleanupAction. It does not remove them (see RemoveCleanupAction) but it does run unlocked, so they may remove themselves.

func ValidateGlobalOptions added in v1.1.4

func ValidateGlobalOptions()

Types

type CleanupActionHandle

type CleanupActionHandle *int

func AddCleanupAction

func AddCleanupAction(fn func()) CleanupActionHandle

AddCleanupAction installs a function that will be called in the event of the whole test being terminated. This allows arbitrary pieces of the overall test to hook into SynchronizedAfterSuite().

type Framework

type Framework struct {
	ClientSet       clientset.Interface
	Cloud           aws.CloudAPI
	ResourceManager *resource.Manager

	Options *Options
	// contains filtered or unexported fields
}

TODO(@M00nF1sh): migrate to use k8s test framework when it's isolated without pull in all dependencies. This is an simplified version of k8s test framework, since some dependencies don't work under go module :(. Framework supports common operations used by e2e tests; it will keep a client & a namespace for you.

func New

func New() *Framework

New makes a new framework and sets up a BeforeEach/AfterEach for you.

func (*Framework) AfterEach

func (f *Framework) AfterEach()

func (*Framework) BeforeEach

func (f *Framework) BeforeEach()

type Options

type Options struct {
	KubeConfig  string
	ClusterName string
	AWSRegion   string
	AWSVPCID    string
}

func (*Options) BindFlags

func (options *Options) BindFlags()

func (*Options) Validate

func (options *Options) Validate() error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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