From a4551ef19ae51a7984bb005eca6ca6a955ea7fc4 Mon Sep 17 00:00:00 2001 From: Abhishek Kr Srivastav Date: Wed, 22 May 2024 14:52:52 +0530 Subject: [PATCH] fixed flaky test by splitting expected output string addressed review comments Kubernetes-commit: 5de6f7cf6167b04892750423228ccd61ac09ddd4 --- pkg/cmd/logs/logs_test.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkg/cmd/logs/logs_test.go b/pkg/cmd/logs/logs_test.go index 61b10ec9..36fa8a70 100644 --- a/pkg/cmd/logs/logs_test.go +++ b/pkg/cmd/logs/logs_test.go @@ -117,7 +117,10 @@ func TestLog(t *testing.T) { o.Prefix = true return o }, - expectedOutSubstrings: []string{"[pod/test-sts-0/test-container] test log content for pod test-sts-0\n[pod/test-sts-1/test-container] test log content for pod test-sts-1\n"}, + expectedOutSubstrings: []string{ + "[pod/test-sts-0/test-container] test log content for pod test-sts-0\n", + "[pod/test-sts-1/test-container] test log content for pod test-sts-1\n", + }, }, { name: "pod logs with prefix: init container",