@@ -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 {
@@ -591,8 +589,9 @@ func TestMachineWithDeleteAnnotation(t *testing.T) {
591
589
}
592
590
593
591
g := NewWithT (t )
594
- annotedMachines := c .MachineWithDeleteAnnotation (machines )
595
- g .Expect (annotedMachines ).NotTo (BeNil ())
592
+ annotatedMachines := c .MachineWithDeleteAnnotation (machines )
593
+ g .Expect (annotatedMachines ).NotTo (BeNil ())
594
+ g .Expect (annotatedMachines .Len ()).To (BeEquivalentTo (2 ))
596
595
})
597
596
}
598
597
0 commit comments