Documentation ¶
Index ¶
- func ConfigMapFromTestFile(t *testing.T, name string) *corev1.ConfigMap
- func SetupFakeContext(t *testing.T) (context.Context, []controller.Informer)
- func SetupFakeContextWithLabelKey(t zaptest.TestingT) (context.Context, context.CancelFunc, []controller.Informer)
- func TestLogger(t *testing.T) *zap.SugaredLogger
- func WithLogger(ctx context.Context, t *testing.T) context.Context
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigMapFromTestFile ¶
ConfigMapFromTestFile creates a v1.ConfigMap from a YAML file It loads the YAML file from the testdata folder.
func SetupFakeContext ¶ added in v0.8.0
SetupFakeContext sets up the the Context and the fake filtered informers for the tests.
func SetupFakeContextWithLabelKey ¶ added in v0.21.0
func SetupFakeContextWithLabelKey(t zaptest.TestingT) (context.Context, context.CancelFunc, []controller.Informer)
SetupFakeContextWithLabelKey sets up the the Context and the fake informers for the tests The provided context includes the FilteredInformerFactory LabelKey.
func TestLogger ¶ added in v0.8.0
func TestLogger(t *testing.T) *zap.SugaredLogger
TestLogger sets up the the Logger
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.