Skip to content

Commit fe06842

Browse files
committed
Drop error condition from AKS node public IP prefix e2e test
1 parent 4ad8f96 commit fe06842

File tree

1 file changed

+2
-23
lines changed

1 file changed

+2
-23
lines changed

test/e2e/aks_public_ip_prefix.go

Lines changed: 2 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ func AKSPublicIPPrefixSpec(ctx context.Context, inputGetter func() AKSPublicIPPr
8484
publicIPPrefix = resp.PublicIPPrefix
8585
}, input.WaitIntervals...).Should(Succeed(), "failed to create public IP prefix")
8686

87-
By("Creating node pool with 3 nodes")
87+
By("Creating node pool with 2 nodes")
8888
infraMachinePool := &infrav1.AzureManagedMachinePool{
8989
ObjectMeta: metav1.ObjectMeta{
9090
Name: "pool3",
@@ -109,7 +109,7 @@ func AKSPublicIPPrefixSpec(ctx context.Context, inputGetter func() AKSPublicIPPr
109109
},
110110
Spec: expv1.MachinePoolSpec{
111111
ClusterName: input.Cluster.Name,
112-
Replicas: ptr.To[int32](3),
112+
Replicas: ptr.To[int32](2),
113113
Template: clusterv1.MachineTemplateSpec{
114114
Spec: clusterv1.MachineSpec{
115115
Bootstrap: clusterv1.Bootstrap{
@@ -145,27 +145,6 @@ func AKSPublicIPPrefixSpec(ctx context.Context, inputGetter func() AKSPublicIPPr
145145
}, input.WaitIntervals...).Should(Succeed(), "Deleted AzureManagedMachinePool %s/%s still exists", infraMachinePool.Namespace, infraMachinePool.Name)
146146
}()
147147

148-
By("Verifying the AzureManagedMachinePool converges to a failed ready status")
149-
Eventually(func(g Gomega) {
150-
infraMachinePool := &infrav1.AzureManagedMachinePool{}
151-
err := mgmtClient.Get(ctx, client.ObjectKeyFromObject(machinePool), infraMachinePool)
152-
g.Expect(err).NotTo(HaveOccurred())
153-
cond := conditions.Get(infraMachinePool, infrav1.AgentPoolsReadyCondition)
154-
g.Expect(cond).NotTo(BeNil())
155-
g.Expect(cond.Status).To(Equal(corev1.ConditionFalse))
156-
g.Expect(cond.Reason).To(Equal(infrav1.FailedReason))
157-
g.Expect(cond.Message).To(ContainSubstring("PublicIpPrefixOutOfIpAddressesForVMScaleSet"))
158-
}, input.WaitIntervals...).Should(Succeed())
159-
160-
By("Scaling the MachinePool to 2 nodes")
161-
Eventually(func(g Gomega) {
162-
err = mgmtClient.Get(ctx, client.ObjectKeyFromObject(machinePool), machinePool)
163-
g.Expect(err).NotTo(HaveOccurred())
164-
machinePool.Spec.Replicas = ptr.To[int32](2)
165-
err = mgmtClient.Update(ctx, machinePool)
166-
g.Expect(err).NotTo(HaveOccurred())
167-
}, input.WaitIntervals...).Should(Succeed())
168-
169148
By("Verifying the AzureManagedMachinePool becomes ready")
170149
Eventually(func(g Gomega) {
171150
infraMachinePool := &infrav1.AzureManagedMachinePool{}

0 commit comments

Comments
 (0)