@@ -176,11 +176,11 @@ var _ = Describe("controller", func() {
176
176
Expect (ctrl .Watch (src , evthdl )).To (Equal (expected ))
177
177
})
178
178
179
- It ("should inject dependencies into the Reconciler" , func () {
179
+ PIt ("should inject dependencies into the Reconciler" , func () {
180
180
// TODO(community): Write this
181
181
})
182
182
183
- It ("should return an error if there is an error injecting into the Reconciler" , func () {
183
+ PIt ("should return an error if there is an error injecting into the Reconciler" , func () {
184
184
// TODO(community): Write this
185
185
})
186
186
@@ -299,7 +299,7 @@ var _ = Describe("controller", func() {
299
299
close (done )
300
300
})
301
301
302
- It ("should forget an item if it is not a Request and continue processing items" , func () {
302
+ PIt ("should forget an item if it is not a Request and continue processing items" , func () {
303
303
// TODO(community): write this test
304
304
})
305
305
@@ -391,19 +391,19 @@ var _ = Describe("controller", func() {
391
391
Eventually (func () int { return ctrl .Queue .NumRequeues (request ) }).Should (Equal (0 ))
392
392
})
393
393
394
- It ("should forget the Request if Reconciler is successful" , func () {
394
+ PIt ("should forget the Request if Reconciler is successful" , func () {
395
395
// TODO(community): write this test
396
396
})
397
397
398
- It ("should return if the queue is shutdown" , func () {
398
+ PIt ("should return if the queue is shutdown" , func () {
399
399
// TODO(community): write this test
400
400
})
401
401
402
- It ("should wait for informers to be synced before processing items" , func () {
402
+ PIt ("should wait for informers to be synced before processing items" , func () {
403
403
// TODO(community): write this test
404
404
})
405
405
406
- It ("should create a new go routine for MaxConcurrentReconciles" , func () {
406
+ PIt ("should create a new go routine for MaxConcurrentReconciles" , func () {
407
407
// TODO(community): write this test
408
408
})
409
409
@@ -533,16 +533,7 @@ var _ = Describe("controller", func() {
533
533
534
534
Context ("should update prometheus metrics" , func () {
535
535
It ("should requeue a Request if there is an error and continue processing items" , func (done Done ) {
536
- var queueLength , reconcileErrs dto.Metric
537
- ctrlmetrics .QueueLength .Reset ()
538
- Expect (func () error {
539
- ctrlmetrics .QueueLength .WithLabelValues (ctrl .Name ).Write (& queueLength )
540
- if queueLength .GetGauge ().GetValue () != 0.0 {
541
- return fmt .Errorf ("metric queue length not reset" )
542
- }
543
- return nil
544
- }()).Should (Succeed ())
545
-
536
+ var reconcileErrs dto.Metric
546
537
ctrlmetrics .ReconcileErrors .Reset ()
547
538
Expect (func () error {
548
539
ctrlmetrics .ReconcileErrors .WithLabelValues (ctrl .Name ).Write (& reconcileErrs )
@@ -564,13 +555,6 @@ var _ = Describe("controller", func() {
564
555
565
556
By ("Invoking Reconciler which will give an error" )
566
557
Expect (<- reconciled ).To (Equal (request ))
567
- Eventually (func () error {
568
- ctrlmetrics .QueueLength .WithLabelValues (ctrl .Name ).Write (& queueLength )
569
- if queueLength .GetGauge ().GetValue () != 1.0 {
570
- return fmt .Errorf ("metric queue length not updated" )
571
- }
572
- return nil
573
- }, 2.0 ).Should (Succeed ())
574
558
Eventually (func () error {
575
559
ctrlmetrics .ReconcileErrors .WithLabelValues (ctrl .Name ).Write (& reconcileErrs )
576
560
if reconcileErrs .GetCounter ().GetValue () != 1.0 {
0 commit comments