corev1_test

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const Namespace = "test"

Namespace for the pods

Variables

View Source
var BadPod = NewBrokenPod("broken")

BadPod is a pod which does not serialize correctly

View Source
var DetachedPod = NewDetachedPod("detached")

DetachedPod is a pod which is not attached to a namespace

View Source
var ErrorPod = NewPod("error")

ErrorPod is a pod which should create an error on handling

View Source
var InvalidPod = NewPod("invalid")

InvalidPod is a pod which is considered invalid on handling

View Source
var PanicPod = NewPod("panic")

PanicPod is a pod which should create a panic on handling

View Source
var PodKind = metav1.GroupVersionKind{Group: corev1.SchemeGroupVersion.Group, Version: corev1.SchemeGroupVersion.Version, Kind: "Pod"}

PodKind is the metav1.GroupVersionKind for corev1.Pod

View Source
var PodTypeMeta = metav1.TypeMeta{
	Kind:       "Pod",
	APIVersion: corev1.SchemeGroupVersion.Group + "/" + corev1.SchemeGroupVersion.Version,
}

PodTypeMeta is the metav1.TypeMeta for corev1.Pod

View Source
var ValidPod = NewPod("valid")

ValidPod is a pod which is considered valid on handling

Functions

This section is empty.

Types

type Pod

type Pod corev1.Pod

Pod extends corev1.Pod for testing

func NewBrokenPod

func NewBrokenPod(name string) *Pod

NewBrokenPod creates a new broken Pod with the provided name

func NewDetachedPod added in v1.4.0

func NewDetachedPod(name string) *Pod

func NewPod

func NewPod(name string) *Pod

NewPod creates a new Pod with the provided name

func (*Pod) AsCoreV1

func (t *Pod) AsCoreV1() *corev1.Pod

func (*Pod) DeepCopyObject

func (t *Pod) DeepCopyObject() runtime.Object

func (*Pod) MustMarshal

func (t *Pod) MustMarshal() []byte

func (*Pod) RawExtension

func (t *Pod) RawExtension() runtime.RawExtension

RawExtension marshals the pod and creates a runtime.RawExtension for which Raw is set to the marshaled JSON

Jump to

Keyboard shortcuts

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