summaryrefslogtreecommitdiff
path: root/test/apiv2
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-06-09 13:27:11 -0400
committerGitHub <noreply@github.com>2022-06-09 13:27:11 -0400
commit874ca426eb51e2b1c9fd1d0c052de2e21f4afd2d (patch)
tree6bbd0f4dfe2240de05bc655cc36684bc98cb995f /test/apiv2
parente5ef9fd5bc9ba959f134411e548e3820444f484c (diff)
parent5614c29ce1132ac8ee05687910248134d0f5c766 (diff)
downloadpodman-874ca426eb51e2b1c9fd1d0c052de2e21f4afd2d.tar.gz
podman-874ca426eb51e2b1c9fd1d0c052de2e21f4afd2d.tar.bz2
podman-874ca426eb51e2b1c9fd1d0c052de2e21f4afd2d.zip
Merge pull request #14549 from Luap99/compat-create
compat api: fix regressions from "Swagger refactor/cleanup"
Diffstat (limited to 'test/apiv2')
-rw-r--r--test/apiv2/20-containers.at15
1 files changed, 4 insertions, 11 deletions
diff --git a/test/apiv2/20-containers.at b/test/apiv2/20-containers.at
index 8f34b7e05..383c527b4 100644
--- a/test/apiv2/20-containers.at
+++ b/test/apiv2/20-containers.at
@@ -240,14 +240,11 @@ t POST containers/create Image=$IMAGE Entrypoint='["top"]' 201 \
.Id~[0-9a-f]\\{64\\}
cid_top=$(jq -r '.Id' <<<"$output")
-# Unexpected difference between /containers/json and /containers/CID/json:
-# in rootless, the former returns .Networks=none, the latter .Networks={}
-network_expect=${network_expect/=null/='{}'}
t GET containers/${cid_top}/json 200 \
.Config.Entrypoint[0]="top" \
.Config.Cmd='[]' \
.Path="top" \
- .NetworkSettings.$network_expect
+ .NetworkSettings.Networks.podman.NetworkID=podman
t POST containers/${cid_top}/start 204
# make sure the container is running
t GET containers/${cid_top}/json 200 \
@@ -378,13 +375,8 @@ t DELETE containers/$cid?v=true 204
t POST containers/create Image=$IMAGE HostConfig='{"NetworkMode":"default"}' 201 \
.Id~[0-9a-f]\\{64\\}
cid=$(jq -r '.Id' <<<"$output")
-if root; then
- network_type=bridge
-else
- network_type=slirp4netns
-fi
t GET containers/$cid/json 200 \
- .HostConfig.NetworkMode="$network_type"
+ .HostConfig.NetworkMode="bridge"
t DELETE containers/$cid?v=true 204
@@ -486,7 +478,8 @@ for endpoint in containers/create libpod/containers/create; do
t POST libpod/containers/$cid/init 204
- t GET libpod/containers/$cid/json 200
+ t GET libpod/containers/$cid/json 200 \
+ .HostsPath=""
t DELETE containers/$cid 204
done