From 8d6a60748be3d00d291fffe4858fd783008cb3fc Mon Sep 17 00:00:00 2001 From: andyzhangx Date: Tue, 3 Oct 2023 14:55:11 +0000 Subject: [PATCH] test: fix DeletePodAndWait failure --- test/e2e/testsuites/testsuites.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/test/e2e/testsuites/testsuites.go b/test/e2e/testsuites/testsuites.go index 7e5b16851..4e3ee7291 100644 --- a/test/e2e/testsuites/testsuites.go +++ b/test/e2e/testsuites/testsuites.go @@ -552,11 +552,9 @@ func (t *TestDeployment) DeletePodAndWait() { return } framework.Logf("Waiting for pod %q in namespace %q to be fully deleted", t.podName, t.namespace.Name) - err = e2epod.WaitForPodNoLongerRunningInNamespace(t.client, t.podName, t.namespace.Name) + err = e2epod.WaitForPodNotFoundInNamespace(t.client, t.podName, t.namespace.Name, e2epod.DefaultPodDeletionTimeout) if err != nil { - if !apierrs.IsNotFound(err) { - framework.ExpectNoError(fmt.Errorf("pod %q error waiting for delete: %v", t.podName, err)) - } + framework.ExpectNoError(fmt.Errorf("pod %q error waiting for delete: %w", t.podName, err)) } }