Merge pull request #106273 from claudiubelu/integration/windows-log-network-consistentcy

tests: Logs the stdout and stderr for network consistency Windows tests on error
This commit is contained in:
Kubernetes Prow Robot 2021-11-09 16:31:39 -08:00 committed by GitHub
commit c04157895c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -92,7 +92,10 @@ func assertConsistentConnectivity(f *framework.Framework, podName string, os str
connChecker := func() error {
ginkgo.By(fmt.Sprintf("checking connectivity of %s-container in %s", os, podName))
// TODO, we should be retrying this similar to what is done in DialFromNode, in the test/e2e/networking/networking.go tests
_, _, err := f.ExecCommandInContainerWithFullOutput(podName, os+"-container", cmd...)
stdout, stderr, err := f.ExecCommandInContainerWithFullOutput(podName, os+"-container", cmd...)
if err != nil {
framework.Logf("Encountered error while running command: %v.\nStdout: %s\nStderr: %s\nErr: %v", cmd, stdout, stderr, err)
}
return err
}
gomega.Eventually(connChecker, duration, pollInterval).ShouldNot(gomega.HaveOccurred())