Documentation ¶
Index ¶
- func MakeFactory(ctor Ctor) rt.Factory
- func NewConfigMap(ns, name string, opts ...ConfigMapOption) *corev1.ConfigMap
- func NewScheme() *runtime.Scheme
- func SetEnvVar(t *testing.T, name, val string) (unset func())
- func ToUnstructured(t *testing.T, sch *runtime.Scheme, objs []runtime.Object) (us []runtime.Object)
- type ConfigMapOption
- type Ctor
- type Listers
- func (l *Listers) GetAppsObjects() []runtime.Object
- func (l *Listers) GetChannelLister() messaginglistersv1alpha1.ChannelLister
- func (l *Listers) GetCoreObjects() []runtime.Object
- func (l *Listers) GetDeploymentLister() appslistersv1.DeploymentLister
- func (l *Listers) GetEventingObjects() []runtime.Object
- func (l *Listers) GetHTTPSourceLister() sourceslistersv1alpha1.HTTPSourceLister
- func (l *Listers) GetIstioObjects() []runtime.Object
- func (l *Listers) GetLegacyObjects() []runtime.Object
- func (l *Listers) GetPeerAuthenticationLister() securitylistersv1alpha1.PeerAuthenticationLister
- func (l *Listers) GetServiceLister() corelistersv1.ServiceLister
- func (l *Listers) GetSourcesObjects() []runtime.Object
- func (l *Listers) IndexerFor(obj runtime.Object) cache.Indexer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MakeFactory ¶
MakeFactory creates a reconciler factory with fake clients and controller created by the given Ctor.
func NewConfigMap ¶
func NewConfigMap(ns, name string, opts ...ConfigMapOption) *corev1.ConfigMap
NewConfigMap creates a ConfigMap object.
func SetEnvVar ¶
SetEnvVar sets the value of an env var and returns a function that can be deferred to unset that variable.
func ToUnstructured ¶
ToUnstructured takes a list of k8s resources and converts them to Unstructured objects. We must pass objects as Unstructured to the dynamic client fake, or it won't handle them properly.
Types ¶
type ConfigMapOption ¶
ConfigMapOption is a functional option for ConfigMap objects.
func WithData ¶
func WithData(data map[string]string) ConfigMapOption
WithData sets the data of a ConfigMap.
type Ctor ¶
type Ctor func(*testing.T, context.Context, *Listers) controller.Reconciler
Ctor functions create a k8s controller with given params.
type Listers ¶
type Listers struct {
// contains filtered or unexported fields
}
func (*Listers) GetAppsObjects ¶
func (*Listers) GetChannelLister ¶
func (l *Listers) GetChannelLister() messaginglistersv1alpha1.ChannelLister
func (*Listers) GetCoreObjects ¶
func (*Listers) GetDeploymentLister ¶
func (l *Listers) GetDeploymentLister() appslistersv1.DeploymentLister
func (*Listers) GetEventingObjects ¶
func (*Listers) GetHTTPSourceLister ¶
func (l *Listers) GetHTTPSourceLister() sourceslistersv1alpha1.HTTPSourceLister
func (*Listers) GetIstioObjects ¶
func (*Listers) GetLegacyObjects ¶
func (*Listers) GetPeerAuthenticationLister ¶
func (l *Listers) GetPeerAuthenticationLister() securitylistersv1alpha1.PeerAuthenticationLister
func (*Listers) GetServiceLister ¶
func (l *Listers) GetServiceLister() corelistersv1.ServiceLister
func (*Listers) GetSourcesObjects ¶
Click to show internal directories.
Click to hide internal directories.