Kaynağa Gözat

test: add more information to potentially flaky test (#5330)

Signed-off-by: Gergely Brautigam <182850+Skarlso@users.noreply.github.com>
Gergely Brautigam 8 ay önce
ebeveyn
işleme
5627d449e5
1 değiştirilmiş dosya ile 10 ekleme ve 4 silme
  1. 10 4
      pkg/controllers/secretstore/common_test.go

+ 10 - 4
pkg/controllers/secretstore/common_test.go

@@ -95,11 +95,17 @@ var _ = Describe("SecretStore Controller", func() {
 					if err != nil {
 						return true
 					}
-					return len(ss.GetStatus().Conditions) == 0
+
+					conditionLen := len(ss.GetStatus().Conditions) == 0
+					if !conditionLen {
+						GinkgoLogr.Info("store conditions is NOT empty but should have been", "conditions", ss.GetStatus().Conditions)
+					}
+
+					return conditionLen
 				}).
-					WithTimeout(time.Second * 3).
-					WithPolling(time.Millisecond * 500).
-					Should(BeTrue())
+					WithTimeout(time.Second*3).
+					WithPolling(time.Millisecond*500).
+					Should(BeTrue(), "condition should have been empty")
 			}
 		}