summaryrefslogtreecommitdiff
path: root/test/apiv2
diff options
context:
space:
mode:
authorPaul Holzinger <pholzing@redhat.com>2022-07-21 13:42:21 +0200
committerPaul Holzinger <pholzing@redhat.com>2022-07-21 15:09:39 +0200
commit80ad0cfd05f970fea46545dc51cad35d14542a59 (patch)
tree04a3975ccef71d335921c9d0c1633513e7bf4742 /test/apiv2
parent712267ee20b7cf4a8bbd73a4f13608f48ffe962b (diff)
downloadpodman-80ad0cfd05f970fea46545dc51cad35d14542a59.tar.gz
podman-80ad0cfd05f970fea46545dc51cad35d14542a59.tar.bz2
podman-80ad0cfd05f970fea46545dc51cad35d14542a59.zip
compat api: allow default bridge name for networks
Docker uses "bridge" as default network name so some tools expect this to work with network list or inspect. To fix this we change "bridge" to the podman default ("podman") name. Fixes #14983 Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'test/apiv2')
-rw-r--r--test/apiv2/35-networks.at12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/apiv2/35-networks.at b/test/apiv2/35-networks.at
index fcff26521..07ba45efb 100644
--- a/test/apiv2/35-networks.at
+++ b/test/apiv2/35-networks.at
@@ -84,12 +84,24 @@ t GET networks?filters='{"dangling":["true","0"]}' 500 \
t GET networks?filters='{"name":["doesnotexists"]}' 200 \
"[]"
+# check default name in list endpoint
+t GET networks 200 \
+ .[].Name~.*bridge.*
+
# network inspect docker
t GET networks/$network1_id 200 \
.Name=network1 \
.Id=$network1_id \
.Scope=local
+# inspect default bridge network
+t GET networks/bridge 200 \
+ .Name=bridge
+
+# inspect default bridge network with real podman name should return real name
+t GET networks/podman 200 \
+ .Name=podman
+
# network create docker
t POST networks/create Name=net3\ IPAM='{"Config":[]}' 201
# network delete docker