From f0343bd86c7eb248074251f532feab0598d20d46 Mon Sep 17 00:00:00 2001 From: Reed Schalo Date: Thu, 26 Sep 2024 16:13:21 -0700 Subject: [PATCH] fix: update test to reduce create fleet payload size --- test/suites/nodeclaim/nodeclaim_test.go | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/test/suites/nodeclaim/nodeclaim_test.go b/test/suites/nodeclaim/nodeclaim_test.go index bc36bd8fd380..dd2f92f8d2a7 100644 --- a/test/suites/nodeclaim/nodeclaim_test.go +++ b/test/suites/nodeclaim/nodeclaim_test.go @@ -48,6 +48,13 @@ var _ = Describe("StandaloneNodeClaim", func() { Values: []string{"c"}, }, }, + { + NodeSelectorRequirement: v1.NodeSelectorRequirement{ + Key: v1.LabelArchStable, + Operator: v1.NodeSelectorOpIn, + Values: []string{"arm64"}, + }, + }, { NodeSelectorRequirement: v1.NodeSelectorRequirement{ Key: corev1beta1.CapacityTypeLabelKey, @@ -201,6 +208,13 @@ var _ = Describe("StandaloneNodeClaim", func() { Values: []string{"c"}, }, }, + { + NodeSelectorRequirement: v1.NodeSelectorRequirement{ + Key: v1.LabelArchStable, + Operator: v1.NodeSelectorOpIn, + Values: []string{"arm64"}, + }, + }, { NodeSelectorRequirement: v1.NodeSelectorRequirement{ Key: corev1beta1.CapacityTypeLabelKey, @@ -226,7 +240,7 @@ var _ = Describe("StandaloneNodeClaim", func() { env.EventuallyExpectNotFound(nodeClaim, node) Eventually(func(g Gomega) { - g.Expect(lo.FromPtr(env.GetInstanceByID(instanceID).State.Name)).To(Equal("shutting-down")) + g.Expect(lo.FromPtr(env.GetInstanceByID(instanceID).State.Name)).To(BeElementOf("shutting-down", "terminated")) }, time.Second*10).Should(Succeed()) }) It("should delete a NodeClaim from the node termination finalizer", func() { @@ -240,6 +254,13 @@ var _ = Describe("StandaloneNodeClaim", func() { Values: []string{"c"}, }, }, + { + NodeSelectorRequirement: v1.NodeSelectorRequirement{ + Key: v1.LabelArchStable, + Operator: v1.NodeSelectorOpIn, + Values: []string{"arm64"}, + }, + }, { NodeSelectorRequirement: v1.NodeSelectorRequirement{ Key: corev1beta1.CapacityTypeLabelKey, @@ -265,7 +286,7 @@ var _ = Describe("StandaloneNodeClaim", func() { env.EventuallyExpectNotFound(nodeClaim, node) Eventually(func(g Gomega) { - g.Expect(lo.FromPtr(env.GetInstanceByID(instanceID).State.Name)).To(Equal("shutting-down")) + g.Expect(lo.FromPtr(env.GetInstanceByID(instanceID).State.Name)).To(BeElementOf("shutting-down", "terminated")) }, time.Second*10).Should(Succeed()) }) It("should create a NodeClaim with custom labels passed through the userData", func() {