From 267e84f1035c9155dc7bec0d794604abd4ed7454 Mon Sep 17 00:00:00 2001 From: Tal Shor Date: Wed, 16 Aug 2023 10:19:12 +0300 Subject: [PATCH] fix tests --- controllers/serviceinstance_controller_test.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/controllers/serviceinstance_controller_test.go b/controllers/serviceinstance_controller_test.go index 4560ed40..2439e802 100644 --- a/controllers/serviceinstance_controller_test.go +++ b/controllers/serviceinstance_controller_test.go @@ -961,10 +961,7 @@ var _ = Describe("ServiceInstance controller", func() { err := k8sClient.Get(ctx, defaultLookupKey, serviceInstance) if err == nil { cond := meta.FindStatusCondition(serviceInstance.GetConditions(), api.ConditionSucceeded) - if cond == nil { - return false - } - return cond.Status == metav1.ConditionTrue && cond.Reason == Deleted + return cond != nil && cond.Status == metav1.ConditionTrue && cond.Reason == Deleted } return false }, timeout, interval).Should(BeTrue())