From 353118c0475c5f6b8212176075b57ae867101655 Mon Sep 17 00:00:00 2001 From: Antonio Ojea Date: Wed, 11 Dec 2024 06:28:32 +0000 Subject: [PATCH] e2e: don't panic asserting inside wait.Poll --- test/e2e/network/dns_common.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/e2e/network/dns_common.go b/test/e2e/network/dns_common.go index 6e602370514..0e007ea62f9 100644 --- a/test/e2e/network/dns_common.go +++ b/test/e2e/network/dns_common.go @@ -490,7 +490,7 @@ func assertFilesContain(ctx context.Context, fileNames []string, fileDir string, if err != nil { if ctx.Err() != nil { - framework.Failf("Unable to read %s from pod %s/%s: %v", fileName, pod.Namespace, pod.Name, err) + return false, fmt.Errorf("Unable to read %s from pod %s/%s: %v", fileName, pod.Namespace, pod.Name, err) } else { framework.Logf("Unable to read %s from pod %s/%s: %v", fileName, pod.Namespace, pod.Name, err) }