@@ -184,14 +184,12 @@ func TestControlPlane(t *testing.T) {
184
184
g .Expect (fd ).To (BeNil ())
185
185
})
186
186
187
- t .Run ("ControlPlane returns infra error " , func (t * testing.T ) {
187
+ t .Run ("ControlPlane returns error when getting infra resources " , func (t * testing.T ) {
188
188
g := NewWithT (t )
189
189
cluster := clusterv1.Cluster {
190
190
Status : clusterv1.ClusterStatus {
191
191
FailureDomains : clusterv1.FailureDomains {
192
- "one" : failureDomain (true ),
193
- "two" : failureDomain (true ),
194
- "three" : failureDomain (true ),
192
+ "one" : failureDomain (true ),
195
193
},
196
194
},
197
195
}
@@ -213,7 +211,7 @@ func TestControlPlane(t *testing.T) {
213
211
g .Expect (err ).To (HaveOccurred ())
214
212
})
215
213
216
- t .Run ("When infra and bootstrap config is exists" , func (t * testing.T ) {
214
+ t .Run ("When infra and bootstrap config exists" , func (t * testing.T ) {
217
215
g := NewWithT (t )
218
216
ns , err := env .CreateNamespace (ctx , "test-machine-watches" )
219
217
kcp := & controlplanev1.KubeadmControlPlane {
@@ -583,8 +581,9 @@ func TestMachineWithDeleteAnnotation(t *testing.T) {
583
581
}
584
582
585
583
g := NewWithT (t )
586
- annotedMachines := c .MachineWithDeleteAnnotation (machines )
587
- g .Expect (annotedMachines ).NotTo (BeNil ())
584
+ annotatedMachines := c .MachineWithDeleteAnnotation (machines )
585
+ g .Expect (annotatedMachines ).NotTo (BeNil ())
586
+ g .Expect (annotatedMachines .Len ()).To (BeEquivalentTo (2 ))
588
587
})
589
588
}
590
589
0 commit comments