support

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: May 21, 2023 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyYaml

func ApplyYaml(ctx context.Context, r *resources.Resources, path string) error

func DumpContainerDbgLogs

func DumpContainerDbgLogs(ctx context.Context, t *testing.T, clientset *kubernetes.Clientset)

func DumpEvents

func DumpEvents(ctx context.Context, t *testing.T, client corev1client.EventsGetter, objOrRef runtime.Object, limit int64)

func DumpLogs

func DumpLogs(ctx context.Context, t *testing.T, podsGetter corev1client.PodsGetter, object runtime.Object)

func EqualProto

func EqualProto(t *testing.T, actual, expected *pb.Event) bool

Although we could use proto.Equal to check for protobuf equality that function uses reflection and slows down the test validation hard enough that we are not reading from the channel fast enough to clean the ring buffer, thus we have to implement the equality check directly.

func GetLogsForObject

func GetLogsForObject(ctx context.Context, podsGetter corev1client.PodsGetter, object runtime.Object) (string, error)

func NewK8sClient

func NewK8sClient(ctx context.Context, t *testing.T, cfg *envconf.Config) (klient.Client, *kubernetes.Clientset)

func NewTestRootCmd

func NewTestRootCmd(cfg *envconf.Config, interruptCh <-chan os.Signal) (*cobra.Command, *bytes.Buffer, *bytes.Buffer, *bytes.Buffer)

func RunContainerDebug

func RunContainerDebug(t *testing.T, ctx context.Context, cfg *envconf.Config, outpath string, namespace string, debugParams ...string) context.Context

Types

This section is empty.

Jump to

Keyboard shortcuts

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