utiltest

package
v0.0.0-...-aeaf823 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DummyAuthMethodConfig

func DummyAuthMethodConfig() *configs.AuthMethod

DummyAuthMethodConfig returns a populated AuthMethod struct

func DummyCompleteConfig

func DummyCompleteConfig() configs.Config

DummyCompleteConfig returns a fully populated Config struct

func DummyConfigNoAuth

func DummyConfigNoAuth() configs.Config

DummyConfigNoAuth returns a populated Config struct but omits the optional AuthMethod

func DummyDashboardConfig

func DummyDashboardConfig() configs.Dashboard

DummyDashboardConfig returns a populated Dashboard struct

func DummyDashboardsConfig

func DummyDashboardsConfig() []configs.Dashboard

DummyDashboardsConfig returns an array of populated Dashboard structs

func InitConfig

func InitConfig(t *testing.T) (conf *config.Config, configPath string,
	kubeConfigPath string, cleanup func(*testing.T))

InitConfig creates a Config object meant for testing.

The returned config object will be associated with real files stored in a directory in the user's temporary file storage This directory can be cleaned up by calling the returned "cleanup" function

func TempDir

func TempDir(t *testing.T, prefix string) (path string, cleanup func(*testing.T))

TempDir creates a new temporary directory in the system's temporary file storage with a name beginning with prefix. It returns the path of the new directory and a function that can be used to easily clean up that directory

Types

This section is empty.

Jump to

Keyboard shortcuts

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