@@ -181,14 +181,12 @@ func TestControlPlane(t *testing.T) {
181
181
g .Expect (fd ).To (BeNil ())
182
182
})
183
183
184
- t .Run ("ControlPlane returns infra error " , func (t * testing.T ) {
184
+ t .Run ("ControlPlane returns error when getting infra resources " , func (t * testing.T ) {
185
185
g := NewWithT (t )
186
186
cluster := clusterv1.Cluster {
187
187
Status : clusterv1.ClusterStatus {
188
188
FailureDomains : clusterv1.FailureDomains {
189
- "one" : failureDomain (true ),
190
- "two" : failureDomain (true ),
191
- "three" : failureDomain (true ),
189
+ "one" : failureDomain (true ),
192
190
},
193
191
},
194
192
}
@@ -210,7 +208,7 @@ func TestControlPlane(t *testing.T) {
210
208
g .Expect (err ).To (HaveOccurred ())
211
209
})
212
210
213
- t .Run ("When infra and bootstrap config is exists" , func (t * testing.T ) {
211
+ t .Run ("When infra and bootstrap config exists" , func (t * testing.T ) {
214
212
g := NewWithT (t )
215
213
ns , err := env .CreateNamespace (ctx , "test-machine-watches" )
216
214
kcp := & controlplanev1.KubeadmControlPlane {
@@ -511,8 +509,9 @@ func TestMachineWithDeleteAnnotation(t *testing.T) {
511
509
}
512
510
513
511
g := NewWithT (t )
514
- annotedMachines := c .MachineWithDeleteAnnotation (machines )
515
- g .Expect (annotedMachines ).NotTo (BeNil ())
512
+ annotatedMachines := c .MachineWithDeleteAnnotation (machines )
513
+ g .Expect (annotatedMachines ).NotTo (BeNil ())
514
+ g .Expect (annotatedMachines .Len ()).To (BeEquivalentTo (2 ))
516
515
})
517
516
}
518
517
0 commit comments