validation

package
v0.0.0-...-2a7b7bc Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2026 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewClusterValidationController

func NewClusterValidationController(
	validation validationutils.ClusterValidation,
	resourcesDBClient corecosmosstorage.ResourcesDBClient,
	serviceProviderClusterLister corelisters.ServiceProviderClusterLister,
	informers coreinformers.BackendInformers,
) controllerutils.Controller

NewClusterValidationController creates a new controller that executes the provided Cluster validation on each cluster.

Types

type MockClusterValidation

type MockClusterValidation struct {
	// contains filtered or unexported fields
}

MockClusterValidation is a ClusterValidation implementation for controller tests.

func NewMockClusterValidation

func NewMockClusterValidation(name string) *MockClusterValidation

NewMockClusterValidation creates a mock validation with the given name and no result configured.

func (*MockClusterValidation) Name

func (m *MockClusterValidation) Name() string

func (*MockClusterValidation) WithEarliestRetryAfter

func (m *MockClusterValidation) WithEarliestRetryAfter(d *time.Duration) *MockClusterValidation

WithEarliestRetryAfter overrides the currently configured result's EarliestRetryAfter, e.g. to nil to exercise the "no retry backoff" path.

func (*MockClusterValidation) WithFailed

func (m *MockClusterValidation) WithFailed(reason, internalMessage, userMessage string) *MockClusterValidation

WithFailed configures the mock to return a failed validation result.

func (*MockClusterValidation) WithPassed

WithPassed configures the mock to return a passed validation result.

func (*MockClusterValidation) WithSkipped

func (m *MockClusterValidation) WithSkipped(reason, internalMessage, userMessage string) *MockClusterValidation

WithSkipped configures the mock to return a skipped validation result.

func (*MockClusterValidation) WithUnknownLogOnly

func (m *MockClusterValidation) WithUnknownLogOnly(reason, internalMessage, userMessage string) *MockClusterValidation

WithUnknownLogOnly configures the mock to return an unknown validation result with log-only reporting.

func (*MockClusterValidation) WithUnknownReportError

func (m *MockClusterValidation) WithUnknownReportError(reason, internalMessage, userMessage string) *MockClusterValidation

WithUnknownReportError configures the mock to return an unknown validation result that reports as an error.

Jump to

Keyboard shortcuts

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