Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateTestServiceWithConditions ¶
func CreateTestServiceWithConditions(name string, readyStatus corev1.ConditionStatus, otherReadyStatus corev1.ConditionStatus, reason string, message string, generations ...int64) runtime.Object
Create a service skeleton with a given ConditionReady status and all other statuses set to otherReadyStatus. Optionally a single generation can be added.
Types ¶
type ConditionsExtractor ¶
type ConditionsExtractor func(obj runtime.Object) (apis.Conditions, error)
Extract conditions from a runtime object
type FakeWatch ¶
type FakeWatch struct { // Record how often stop was called StopCalled int // contains filtered or unexported fields }
Helper for testing watch functionality
func NewFakeWatch ¶
Create a new fake watch with the given events which will be send when on start
func (*FakeWatch) ResultChan ¶
Channel for getting the events
type MessageCallback ¶
Callback for event messages
func SimpleMessageCallback ¶
func SimpleMessageCallback(out io.Writer) MessageCallback
A simple message callback which prints out messages line by line
type WaitForReady ¶
type WaitForReady interface { // Wait on resource the resource with this name until a given timeout // and write event messages for unknown event to the status writer Wait(name string, timeout time.Duration, msgCallback MessageCallback) (error, time.Duration) }
Interface used for waiting of a resource of a given name to reach a definitive state in its "Ready" condition.
func NewWaitForReady ¶
func NewWaitForReady(kind string, watchFunc WatchFunc, extractor ConditionsExtractor) WaitForReady
Constructor with resource type specific configuration
Click to show internal directories.
Click to hide internal directories.