Documentation ¶
Index ¶
- Constants
- Variables
- func ClusterConfigImportTime(time metav1.Time) fake.ClusterConfigMutator
- func ClusterConfigImportToken(t string) fake.ClusterConfigMutator
- func ClusterConfigSyncTime() fake.ClusterConfigMutator
- func ClusterConfigSyncToken() fake.ClusterConfigMutator
- func MarkForDeletion() core.MetaMutator
- func NamespaceConfigImportTime(time metav1.Time) core.MetaMutator
- func NamespaceConfigImportToken(t string) core.MetaMutator
- func NamespaceConfigSyncTime() core.MetaMutator
- func NamespaceConfigSyncToken() core.MetaMutator
- func Now() metav1.Time
- func ToUnstructuredList(t *testing.T, converter runtime.UnstructuredConverter, objs ...client.Object) []*unstructured.Unstructured
Constants ¶
const Token = "b38239ea8f58eaed17af6734bd6a025eeafccda1"
Token is a test sync token.
Variables ¶
var ( // Converter is an unstructured.Unstructured converter used for testing. Converter = runtime.NewTestUnstructuredConverter(conversion.EqualitiesOrDie()) // ManagementEnabled sets management labels and annotations on the object. ManagementEnabled core.MetaMutator = func(obj client.Object) { core.SetAnnotation(obj, metadata.ResourceManagementKey, metadata.ResourceManagementEnabled) core.SetAnnotation(obj, metadata.ResourceIDKey, core.GKNN(obj)) core.SetLabel(obj, metadata.ManagedByKey, metadata.ManagedByValue) } // ManagementDisabled sets the management disabled annotation on the object. ManagementDisabled = core.Annotation(metadata.ResourceManagementKey, metadata.ResourceManagementDisabled) // ManagementInvalid sets an invalid management annotation on the object. ManagementInvalid = core.Annotation(metadata.ResourceManagementKey, "invalid") // TokenAnnotation sets the sync token annotation on the object TokenAnnotation = core.Annotation(metadata.SyncTokenAnnotationKey, Token) )
Functions ¶
func ClusterConfigImportTime ¶
func ClusterConfigImportTime(time metav1.Time) fake.ClusterConfigMutator
ClusterConfigImportTime adds an ImportTime to a ClusterConfig.
func ClusterConfigImportToken ¶
func ClusterConfigImportToken(t string) fake.ClusterConfigMutator
ClusterConfigImportToken adds an import token to a ClusterConfig.
func ClusterConfigSyncTime ¶
func ClusterConfigSyncTime() fake.ClusterConfigMutator
ClusterConfigSyncTime adds a SyncTime to a ClusterConfig.
func ClusterConfigSyncToken ¶
func ClusterConfigSyncToken() fake.ClusterConfigMutator
ClusterConfigSyncToken adds a sync token to a ClusterConfig.
func MarkForDeletion ¶
func MarkForDeletion() core.MetaMutator
MarkForDeletion marks a NamespaceConfig with an intent to be delete
func NamespaceConfigImportTime ¶
func NamespaceConfigImportTime(time metav1.Time) core.MetaMutator
NamespaceConfigImportTime adds an ImportTime to a Namespace Config.
func NamespaceConfigImportToken ¶
func NamespaceConfigImportToken(t string) core.MetaMutator
NamespaceConfigImportToken adds an import token to a Namespace Config.
func NamespaceConfigSyncTime ¶
func NamespaceConfigSyncTime() core.MetaMutator
NamespaceConfigSyncTime adds a sync time to a Namespace Config.
func NamespaceConfigSyncToken ¶
func NamespaceConfigSyncToken() core.MetaMutator
NamespaceConfigSyncToken adds a sync token to a Namespace Config.
func ToUnstructuredList ¶
func ToUnstructuredList(t *testing.T, converter runtime.UnstructuredConverter, objs ...client.Object) []*unstructured.Unstructured
ToUnstructuredList converts the objects to an unstructured.UnstructedList.
Types ¶
This section is empty.