k8stest

package
v0.24.0 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockClient

type MockClient struct {
	FnDeploymentList              func(ctx context.Context, namespace string) (*v1.DeploymentList, error)
	FnDeploymentRestart           func(ctx context.Context, namespace, name string) error
	FnIngressCreate               func(ctx context.Context, namespace string, ingress *networkingv1.Ingress) error
	FnIngressExists               func(ctx context.Context, namespace string, ingress string) bool
	FnIngressUpdate               func(ctx context.Context, namespace string, ingress *networkingv1.Ingress) error
	FnNamespaceCreate             func(ctx context.Context, namespace string) error
	FnNamespaceExists             func(ctx context.Context, namespace string) bool
	FnNamespaceDelete             func(ctx context.Context, namespace string) error
	FnPersistentVolumeCreate      func(ctx context.Context, namespace, name string) error
	FnPersistentVolumeExists      func(ctx context.Context, namespace, name string) bool
	FnPersistentVolumeDelete      func(ctx context.Context, namespace, name string) error
	FnPersistentVolumeClaimCreate func(ctx context.Context, namespace, name, volumeName string) error
	FnPersistentVolumeClaimExists func(ctx context.Context, namespace, name, volumeName string) bool
	FnPersistentVolumeClaimDelete func(ctx context.Context, namespace, name, volumeName string) error
	FnSecretCreateOrUpdate        func(ctx context.Context, secret corev1.Secret) error
	FnSecretDeleteCollection      func(ctx context.Context, namespace, _type string) error
	FnSecretGet                   func(ctx context.Context, namespace, name string) (*corev1.Secret, error)
	FnServerVersionGet            func() (string, error)
	FnServiceGet                  func(ctx context.Context, namespace, name string) (*corev1.Service, error)
	FnEventsWatch                 func(ctx context.Context, namespace string) (watch.Interface, error)
	FnLogsGet                     func(ctx context.Context, namespace string, name string) (string, error)
	FnStreamPodLogs               func(ctx context.Context, namespace, podName string, since time.Time) (io.ReadCloser, error)
	FnPodList                     func(ctx context.Context, namespace string) (*corev1.PodList, error)
}

func (*MockClient) DeploymentList

func (m *MockClient) DeploymentList(ctx context.Context, namespace string) (*v1.DeploymentList, error)

func (*MockClient) DeploymentRestart

func (m *MockClient) DeploymentRestart(ctx context.Context, namespace, name string) error

func (*MockClient) EventsWatch

func (m *MockClient) EventsWatch(ctx context.Context, namespace string) (watch.Interface, error)

func (*MockClient) IngressCreate

func (m *MockClient) IngressCreate(ctx context.Context, namespace string, ingress *networkingv1.Ingress) error

func (*MockClient) IngressExists

func (m *MockClient) IngressExists(ctx context.Context, namespace string, ingress string) bool

func (*MockClient) IngressUpdate

func (m *MockClient) IngressUpdate(ctx context.Context, namespace string, ingress *networkingv1.Ingress) error

func (*MockClient) LogsGet

func (m *MockClient) LogsGet(ctx context.Context, namespace string, name string) (string, error)

func (*MockClient) NamespaceCreate

func (m *MockClient) NamespaceCreate(ctx context.Context, namespace string) error

func (*MockClient) NamespaceDelete

func (m *MockClient) NamespaceDelete(ctx context.Context, namespace string) error

func (*MockClient) NamespaceExists

func (m *MockClient) NamespaceExists(ctx context.Context, namespace string) bool

func (*MockClient) PersistentVolumeClaimCreate

func (m *MockClient) PersistentVolumeClaimCreate(ctx context.Context, namespace, name, volumeName string) error

func (*MockClient) PersistentVolumeClaimDelete

func (m *MockClient) PersistentVolumeClaimDelete(ctx context.Context, namespace, name, volumeName string) error

func (*MockClient) PersistentVolumeClaimExists

func (m *MockClient) PersistentVolumeClaimExists(ctx context.Context, namespace, name, volumeName string) bool

func (*MockClient) PersistentVolumeCreate

func (m *MockClient) PersistentVolumeCreate(ctx context.Context, namespace, name string) error

func (*MockClient) PersistentVolumeDelete

func (m *MockClient) PersistentVolumeDelete(ctx context.Context, namespace, name string) error

func (*MockClient) PersistentVolumeExists

func (m *MockClient) PersistentVolumeExists(ctx context.Context, namespace, name string) bool

func (*MockClient) PodList added in v0.16.0

func (m *MockClient) PodList(ctx context.Context, namespace string) (*corev1.PodList, error)

func (*MockClient) SecretCreateOrUpdate

func (m *MockClient) SecretCreateOrUpdate(ctx context.Context, secret corev1.Secret) error

func (*MockClient) SecretDeleteCollection added in v0.24.0

func (m *MockClient) SecretDeleteCollection(ctx context.Context, namespace, _type string) error

func (*MockClient) SecretGet

func (m *MockClient) SecretGet(ctx context.Context, namespace, name string) (*corev1.Secret, error)

func (*MockClient) ServerVersionGet

func (m *MockClient) ServerVersionGet() (string, error)

func (*MockClient) ServiceGet

func (m *MockClient) ServiceGet(ctx context.Context, namespace, name string) (*corev1.Service, error)

func (*MockClient) StreamPodLogs added in v0.15.0

func (m *MockClient) StreamPodLogs(ctx context.Context, namespace string, podName string, since time.Time) (io.ReadCloser, error)

Jump to

Keyboard shortcuts

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