Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EqualFromYamlFile ¶
func EqualFromYamlFile[k8sobject comparable](t *testing.T, expectedYamlFile string, actual client.Object, s runtime.ObjectTyper)
Types ¶
type TestCase ¶
type TestCase[k8sObject client.Object] struct { // Permit to lauch some preaction, like init mock PreTest func(stepName *string, data map[string]any) error Steps []TestStep[k8sObject] // contains filtered or unexported fields }
func NewTestCase ¶
type TestStep ¶
type TestStep[k8sObject client.Object] struct { Name string Pre func(c client.Client, data map[string]any) error Do func(c client.Client, key types.NamespacedName, o k8sObject, data map[string]any) error Check func(t *testing.T, c client.Client, key types.NamespacedName, o k8sObject, data map[string]any) error }
Click to show internal directories.
Click to hide internal directories.