Merge pull request #129707 from soltysh/expand_portforward_errors

e2e: expand error conditions when test-ing port-forward
This commit is contained in:
Kubernetes Prow Robot 2025-01-20 05:36:40 -08:00 committed by GitHub
commit 78ad9a7b97
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -617,7 +617,7 @@ var _ = SIGDescribe("Kubectl Port forwarding", func() {
// this error indicates timeout when POST-ing data
gomega.ContainSubstring("context deadline exceeded"),
// this will happen when trying to write to a closed connection
gomega.ContainSubstring("write: broken pipe")))
gomega.ContainSubstring("write: broken pipe"), gomega.ContainSubstring("closed network connection")))
ginkgo.By("Check kubectl port-forward exit code")
gomega.Expect(cmd.cmd.ProcessState.ExitCode()).To(gomega.BeNumerically("<", 0), "kubectl port-forward should finish with non-zero exit code")