From f67859ffb396be13cb8c4b8d91343b77de4eb288 Mon Sep 17 00:00:00 2001 From: Chris Evich Date: Thu, 28 Feb 2019 09:38:02 -0500 Subject: Fix SystemExec completion race Some callers assume when SystemExec returns, the command has completed. Other callers explicitly wait for completion (as required). However, forgetting to do that is an incredibly easy mistake to make. Fix this by adding an explicit parameter to the function. This requires every caller to deliberately state whether or not a completion-check is required. Also address **many** resource naming / cleanup completion-races. Signed-off-by: Chris Evich --- test/e2e/pod_create_test.go | 2 -- 1 file changed, 2 deletions(-) (limited to 'test/e2e/pod_create_test.go') diff --git a/test/e2e/pod_create_test.go b/test/e2e/pod_create_test.go index cb2b0e7b0..4717267a1 100644 --- a/test/e2e/pod_create_test.go +++ b/test/e2e/pod_create_test.go @@ -95,7 +95,6 @@ var _ = Describe("Podman pod create", func() { Expect(webserver.ExitCode()).To(Equal(0)) check := SystemExec("nc", []string{"-z", "localhost", "80"}) - check.WaitWithDefaultTimeout() Expect(check.ExitCode()).To(Equal(1)) }) @@ -111,7 +110,6 @@ var _ = Describe("Podman pod create", func() { Expect(webserver.ExitCode()).To(Equal(0)) check := SystemExec("nc", []string{"-z", "localhost", "80"}) - check.WaitWithDefaultTimeout() Expect(check.ExitCode()).To(Equal(0)) }) -- cgit v1.2.3-54-g00ecf