summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-05-19 07:52:58 -0400
committerGitHub <noreply@github.com>2021-05-19 07:52:58 -0400
commit18efc5a3a78ba7352e42517ba251212833b4583d (patch)
tree57605396a38a648944fe7b3da76e623a5694cc74 /test
parent40025895461cb9b3b22f0f7cbe92ccad75ad637c (diff)
parent92e858914d1a3515ffa1017c5adaad3ef5d89f5b (diff)
downloadpodman-18efc5a3a78ba7352e42517ba251212833b4583d.tar.gz
podman-18efc5a3a78ba7352e42517ba251212833b4583d.tar.bz2
podman-18efc5a3a78ba7352e42517ba251212833b4583d.zip
Merge pull request #10371 from matejvasek/fix-wait-compat
fix: response of containers wait endpoint
Diffstat (limited to 'test')
-rw-r--r--test/apiv2/26-containersWait.at4
-rw-r--r--test/apiv2/python/rest_api/test_v2_0_0_container.py2
2 files changed, 4 insertions, 2 deletions
diff --git a/test/apiv2/26-containersWait.at b/test/apiv2/26-containersWait.at
index ec16c35df..55bcd4592 100644
--- a/test/apiv2/26-containersWait.at
+++ b/test/apiv2/26-containersWait.at
@@ -21,7 +21,9 @@ t POST "containers/${CTR}/wait?condition=non-existent-cond" 400
t POST "containers/${CTR}/wait?condition=not-running" 200
-t POST "containers/${CTR}/wait?condition=next-exit" 200 &
+t POST "containers/${CTR}/wait?condition=next-exit" 200 \
+ .StatusCode=0 \
+ .Error=null &
child_pid=$!
podman start "${CTR}"
wait "${child_pid}"
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 70c07d47f..ad096ed38 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
@@ -99,7 +99,7 @@ class ContainerTestCase(APITestCase):
r = requests.post(self.podman_url + f"/v1.40/containers/{create['Id']}/wait")
self.assertEqual(r.status_code, 200, r.text)
wait = r.json()
- self.assertEqual(wait["StatusCode"], 0, wait["Error"]["Message"])
+ self.assertEqual(wait["StatusCode"], 0, wait["Error"])
prune = requests.post(self.podman_url + "/v1.40/containers/prune")
self.assertEqual(prune.status_code, 200, prune.status_code)