From 0fc78b9bcc54d572e3de9eae75029de026a49114 Mon Sep 17 00:00:00 2001 From: Patrick Ohly Date: Thu, 11 Jul 2024 16:40:10 +0200 Subject: [PATCH] DRA resource claim controller: update test The resource claim controller is completely agnostic to the claim spec. It doesn't care about classes or devices, therefore it needs no changes in 1.31 besides the v1alpha2 -> v1alpha3 renaming from a previous commit. --- pkg/controller/resourceclaim/controller_test.go | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/pkg/controller/resourceclaim/controller_test.go b/pkg/controller/resourceclaim/controller_test.go index 789f0cd4019..9921c88a198 100644 --- a/pkg/controller/resourceclaim/controller_test.go +++ b/pkg/controller/resourceclaim/controller_test.go @@ -527,9 +527,6 @@ func TestSyncHandler(t *testing.T) { func makeClaim(name, namespace, classname string, owner *metav1.OwnerReference) *resourceapi.ResourceClaim { claim := &resourceapi.ResourceClaim{ ObjectMeta: metav1.ObjectMeta{Name: name, Namespace: namespace}, - Spec: resourceapi.ResourceClaimSpec{ - ResourceClassName: classname, - }, } if owner != nil { claim.OwnerReferences = []metav1.OwnerReference{*owner} @@ -546,9 +543,6 @@ func makeGeneratedClaim(podClaimName, generateName, namespace, classname string, Namespace: namespace, Annotations: map[string]string{"resource.kubernetes.io/pod-claim-name": podClaimName}, }, - Spec: resourceapi.ResourceClaimSpec{ - ResourceClassName: classname, - }, } if owner != nil { claim.OwnerReferences = []metav1.OwnerReference{*owner} @@ -604,11 +598,6 @@ func makePod(name, namespace string, uid types.UID, podClaims ...v1.PodResourceC func makeTemplate(name, namespace, classname string) *resourceapi.ResourceClaimTemplate { template := &resourceapi.ResourceClaimTemplate{ ObjectMeta: metav1.ObjectMeta{Name: name, Namespace: namespace}, - Spec: resourceapi.ResourceClaimTemplateSpec{ - Spec: resourceapi.ResourceClaimSpec{ - ResourceClassName: classname, - }, - }, } return template }