diff --git a/connectivity/check/deployment.go b/connectivity/check/deployment.go index d4e11d2196..8af5b03e91 100644 --- a/connectivity/check/deployment.go +++ b/connectivity/check/deployment.go @@ -649,6 +649,9 @@ func (ct *ConnectivityTest) deleteDeployments(ctx context.Context, client *k8s.C ct.Logf("⌛ [%s] Waiting for namespace %s to disappear", client.ClusterName(), ct.params.TestNamespace) for err == nil { time.Sleep(time.Second) + // Retry the namespace deletion in-case the previous delete was + // rejected, i.e. by yahoo/k8s-namespace-guard + _ = client.DeleteNamespace(ctx, ct.params.TestNamespace, metav1.DeleteOptions{}) _, err = client.GetNamespace(ctx, ct.params.TestNamespace, metav1.GetOptions{}) } }