From a1bab96c3d7aedbd09d9b574f60456fba8d78934 Mon Sep 17 00:00:00 2001 From: Nick Tran Date: Mon, 8 Jul 2024 13:50:59 -0700 Subject: [PATCH 1/5] fixTests --- test/pkg/environment/common/setup.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/pkg/environment/common/setup.go b/test/pkg/environment/common/setup.go index aeaa5106b..71d42dd66 100644 --- a/test/pkg/environment/common/setup.go +++ b/test/pkg/environment/common/setup.go @@ -56,12 +56,12 @@ var ( &v1.PersistentVolumeClaim{}, &v1.PersistentVolume{}, &storagev1.StorageClass{}, - &v1beta1.NodePool{}, - &v1.LimitRange{}, - &schedulingv1.PriorityClass{}, &v1.Node{}, &v1beta1.NodeClaim{}, + &v1beta1.NodePool{}, &v1alpha1.KWOKNodeClass{}, + &v1.LimitRange{}, + &schedulingv1.PriorityClass{}, } ) From 77826ac346b0bdf1ef110842998def969fafcfb1 Mon Sep 17 00:00:00 2001 From: Nick Tran Date: Mon, 8 Jul 2024 14:32:27 -0700 Subject: [PATCH 2/5] remove foreground --- test/pkg/environment/common/setup.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/pkg/environment/common/setup.go b/test/pkg/environment/common/setup.go index 71d42dd66..6676f687b 100644 --- a/test/pkg/environment/common/setup.go +++ b/test/pkg/environment/common/setup.go @@ -135,7 +135,7 @@ func (env *Environment) CleanupObjects(cleanableObjects ...client.Object) { defer GinkgoRecover() g.Expect(env.ExpectTestingFinalizerRemoved(&metaList.Items[i])).To(Succeed()) g.Expect(client.IgnoreNotFound(env.Client.Delete(env, &metaList.Items[i], - client.PropagationPolicy(metav1.DeletePropagationForeground), + // client.PropagationPolicy(metav1.DeletePropagationForeground), &client.DeleteOptions{GracePeriodSeconds: lo.ToPtr(int64(0))}))).To(Succeed()) }) // If the deletes eventually succeed, we should have no elements here at the end of the test From 356fd4a90b6363f5a00b238ce3c44231b04c557c Mon Sep 17 00:00:00 2001 From: Nick Tran Date: Mon, 8 Jul 2024 14:33:35 -0700 Subject: [PATCH 3/5] reorder --- test/pkg/environment/common/setup.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/pkg/environment/common/setup.go b/test/pkg/environment/common/setup.go index 6676f687b..ed4e826ca 100644 --- a/test/pkg/environment/common/setup.go +++ b/test/pkg/environment/common/setup.go @@ -56,12 +56,12 @@ var ( &v1.PersistentVolumeClaim{}, &v1.PersistentVolume{}, &storagev1.StorageClass{}, - &v1.Node{}, - &v1beta1.NodeClaim{}, &v1beta1.NodePool{}, - &v1alpha1.KWOKNodeClass{}, &v1.LimitRange{}, &schedulingv1.PriorityClass{}, + &v1.Node{}, + &v1beta1.NodeClaim{}, + &v1alpha1.KWOKNodeClass{}, } ) From e128d086e3689ccfbdaa15576436af4abb91afd5 Mon Sep 17 00:00:00 2001 From: Nick Tran Date: Mon, 8 Jul 2024 15:11:58 -0700 Subject: [PATCH 4/5] fix order of deletion --- hack/install-kwok.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hack/install-kwok.sh b/hack/install-kwok.sh index b4fad4124..ddc2c97b0 100755 --- a/hack/install-kwok.sh +++ b/hack/install-kwok.sh @@ -112,8 +112,8 @@ crdURL="https://github.com/${KWOK_REPO}/releases/download/${KWOK_RELEASE}/stage- # Set UNINSTALL_KWOK=true if you want to uninstall. if [[ ${UNINSTALL_KWOK} = "true" ]] then - kubectl delete -f ${HOME_DIR}/kwok.yaml kubectl delete -f ${crdURL} + kubectl delete -f ${HOME_DIR}/kwok.yaml else kubectl apply -f ${HOME_DIR}/kwok.yaml kubectl apply -f ${crdURL} From 2e9c40d0b577713197c3593f4150c8c1ca6cda1d Mon Sep 17 00:00:00 2001 From: Nick Tran Date: Mon, 8 Jul 2024 15:26:39 -0700 Subject: [PATCH 5/5] removecomment --- test/pkg/environment/common/setup.go | 1 - 1 file changed, 1 deletion(-) diff --git a/test/pkg/environment/common/setup.go b/test/pkg/environment/common/setup.go index ed4e826ca..e99e9fee8 100644 --- a/test/pkg/environment/common/setup.go +++ b/test/pkg/environment/common/setup.go @@ -135,7 +135,6 @@ func (env *Environment) CleanupObjects(cleanableObjects ...client.Object) { defer GinkgoRecover() g.Expect(env.ExpectTestingFinalizerRemoved(&metaList.Items[i])).To(Succeed()) g.Expect(client.IgnoreNotFound(env.Client.Delete(env, &metaList.Items[i], - // client.PropagationPolicy(metav1.DeletePropagationForeground), &client.DeleteOptions{GracePeriodSeconds: lo.ToPtr(int64(0))}))).To(Succeed()) }) // If the deletes eventually succeed, we should have no elements here at the end of the test