summaryrefslogtreecommitdiff
path: root/test/apiv2/python
diff options
context:
space:
mode:
authorValentin Rothberg <rothberg@redhat.com>2022-01-18 16:27:33 +0100
committerValentin Rothberg <rothberg@redhat.com>2022-01-18 16:32:38 +0100
commit7e30531f20b8c367aad81454abda8505a0d9962a (patch)
treedce3216d71c03f5291e17b56f5eb4a5c2427d742 /test/apiv2/python
parent0bbf8fa14035371cdc5bb04f5db51da8a8f94d48 (diff)
downloadpodman-7e30531f20b8c367aad81454abda8505a0d9962a.tar.gz
podman-7e30531f20b8c367aad81454abda8505a0d9962a.tar.bz2
podman-7e30531f20b8c367aad81454abda8505a0d9962a.zip
compat attach: fix write on closed channel
Waiting on an initialized sync.WaitGroup returns immediately. Hence, move the goroutine to wait and close *after* reading the logs. Fixes: #12904 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Diffstat (limited to 'test/apiv2/python')
-rw-r--r--test/apiv2/python/rest_api/test_v2_0_0_container.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/apiv2/python/rest_api/test_v2_0_0_container.py b/test/apiv2/python/rest_api/test_v2_0_0_container.py
index 1b4597cf8..0386116a8 100644
--- a/test/apiv2/python/rest_api/test_v2_0_0_container.py
+++ b/test/apiv2/python/rest_api/test_v2_0_0_container.py
@@ -130,7 +130,7 @@ class ContainerTestCase(APITestCase):
def test_attach(self):
self.skipTest("FIXME: Test timeouts")
- r = requests.post(self.uri(self.resolve_container("/containers/{}/attach")), timeout=5)
+ r = requests.post(self.uri(self.resolve_container("/containers/{}/attach?logs=true")), timeout=5)
self.assertIn(r.status_code, (101, 500), r.text)
def test_logs(self):