diff --git a/test/util/e2e.go b/test/util/e2e.go index d8cc6628b7..cddc95fa6c 100644 --- a/test/util/e2e.go +++ b/test/util/e2e.go @@ -91,17 +91,6 @@ func waitForOperatorAvailability(ctx context.Context, k8sClient client.Client, k gomega.EventuallyWithOffset(2, func(g gomega.Gomega) error { g.Expect(k8sClient.Get(ctx, key, deployment)).To(gomega.Succeed()) g.Expect(k8sClient.List(ctx, pods, client.InNamespace(GetNamespace()), client.MatchingLabels(deployment.Spec.Selector.MatchLabels))).To(gomega.Succeed()) - for _, pod := range pods.Items { - for _, cs := range pod.Status.ContainerStatuses { - // To make sure that we don't have restarts of controller-manager. - // If we have that's mean that something went wrong, and there is - // no needs to continue trying check availability. - if cs.RestartCount > 0 { - return gomega.StopTrying(fmt.Sprintf("%q in %q has restarted %d times", cs.Name, pod.Name, cs.RestartCount)) - } - } - } - // To verify that webhooks are ready, checking is deployment have condition Available=True. g.Expect(deployment.Status.Conditions).To(gomega.ContainElement(gomega.BeComparableTo( appsv1.DeploymentCondition{Type: appsv1.DeploymentAvailable, Status: corev1.ConditionTrue}, cmpopts.IgnoreFields(appsv1.DeploymentCondition{}, "Reason", "Message", "LastUpdateTime", "LastTransitionTime")),