Documentation ¶
Index ¶
- Variables
- func FromJSON[O interface{}](str string) O
- func FromYAML[O interface{}](str string) O
- func Get[K comparable, V interface{}](tc *TestContext, key K) (V, bool)
- func HasAnnotations[O metav1.Object](obj O, labels map[string]string) error
- func HasLabels[O metav1.Object](obj O, labels map[string]string) error
- func Key[O metav1.Object](obj O) relatedresource.Key
- func MapFor[M comparable, K comparable, V interface{}](tc *TestContext, mapKey M, doFunc func(K, V))
- func MapGet[M comparable, K comparable, V interface{}](tc *TestContext, mapKey M, key K) (V, bool)
- func MapSet[M comparable, K comparable, V interface{}](tc *TestContext, mapKey M, key K, value V)
- func MatchAnnotations[O metav1.Object](obj O, labels map[string]string) error
- func MatchLabels[O metav1.Object](obj O, labels map[string]string) error
- func MustRenderValue[O interface{}](tc *TestContext, path string) O
- func RenderValue[O interface{}](tc *TestContext, path string) (O, bool)
- func Select[O metav1.Object](name string, namespace string, obj O) bool
- func Store[K comparable, V interface{}](tc *TestContext, key K, value V)
- func ToJSON[O interface{}](obj O) string
- func ToYAML[O interface{}](obj O) string
- type ChainedCheckFunc
- func NewChainedCheckFunc[S interface{}](checkFuncWithContext func(tc *TestContext, objStruct S)) ChainedCheckFunc
- func OnResources[O metav1.Object](typedListCheckFunc func(tc *TestContext, objects []O)) ChainedCheckFunc
- func OnWorkloads(...) ChainedCheckFunc
- func Once(checkFunc func(tc *TestContext)) ChainedCheckFunc
- func PerResource[O metav1.Object](typedCheckFunc func(tc *TestContext, object O)) ChainedCheckFunc
- func PerWorkload(...) ChainedCheckFunc
- type CheckFunc
- type Checker
- type TestContext
Constants ¶
This section is empty.
Variables ¶
View Source
var (
Scheme = runtime.NewScheme()
)
Functions ¶
func Get ¶
func Get[K comparable, V interface{}](tc *TestContext, key K) (V, bool)
func MapFor ¶
func MapFor[M comparable, K comparable, V interface{}](tc *TestContext, mapKey M, doFunc func(K, V))
func MapGet ¶
func MapGet[M comparable, K comparable, V interface{}](tc *TestContext, mapKey M, key K) (V, bool)
func MapSet ¶
func MapSet[M comparable, K comparable, V interface{}](tc *TestContext, mapKey M, key K, value V)
func MatchAnnotations ¶
func MustRenderValue ¶
func MustRenderValue[O interface{}](tc *TestContext, path string) O
func RenderValue ¶
func RenderValue[O interface{}](tc *TestContext, path string) (O, bool)
func Store ¶
func Store[K comparable, V interface{}](tc *TestContext, key K, value V)
Types ¶
type ChainedCheckFunc ¶
type ChainedCheckFunc func(t *TestContext) CheckFunc
func NewChainedCheckFunc ¶
func NewChainedCheckFunc[S interface{}](checkFuncWithContext func(tc *TestContext, objStruct S)) ChainedCheckFunc
func OnResources ¶
func OnResources[O metav1.Object](typedListCheckFunc func(tc *TestContext, objects []O)) ChainedCheckFunc
func OnWorkloads ¶
func OnWorkloads(typedCheckFunc func(tc *TestContext, podTemplateSpecs map[metav1.Object]corev1.PodTemplateSpec)) ChainedCheckFunc
func Once ¶
func Once(checkFunc func(tc *TestContext)) ChainedCheckFunc
func PerResource ¶
func PerResource[O metav1.Object](typedCheckFunc func(tc *TestContext, object O)) ChainedCheckFunc
func PerWorkload ¶
func PerWorkload(typedCheckFunc func(tc *TestContext, obj metav1.Object, podTemplateSpec corev1.PodTemplateSpec)) ChainedCheckFunc
type CheckFunc ¶
type CheckFunc interface{}
func NewCheckFunc ¶
func NewCheckFunc(funcs ...ChainedCheckFunc) CheckFunc
type Checker ¶
func NewCheckerFromObjectSet ¶
type TestContext ¶
type TestContext struct { T *testing.T Data map[interface{}]interface{} RenderValues helmChartUtil.Values // contains filtered or unexported fields }
func NewContext ¶
func NewContext() *TestContext
func (*TestContext) Continue ¶
func (tc *TestContext) Continue()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.