From 7411d616922abb692954fb536e80bf27cee36578 Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Sat, 10 Feb 2024 16:07:21 +0100 Subject: [PATCH] test: Adjust for `podman inspect` change for "all addresses" https://github.com/containers/podman/pull/21601 changes the output for "bind port to all addresses" from "" to "0.0.0.0". Adjust the test to accept either format. --- test/check-application | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/check-application b/test/check-application index fdd9ea30d..c1ebed28f 100755 --- a/test/check-application +++ b/test/check-application @@ -1903,9 +1903,9 @@ class TestApplication(testlib.MachineCase): '7001/tcp') ports = self.execute(auth, "podman inspect --format '{{.NetworkSettings.Ports}}' busybox-with-tty") - self.assertIn('5000/tcp:[{ 6000}]', ports) + self.assertRegex(ports, r'5000/tcp:\[{(0.0.0.0)? 6000}\]') self.assertIn('5001/udp:[{127.0.0.1 6001}]', ports) - self.assertIn('8001/tcp:[{ ', ports) + self.assertIn('8001/tcp:[{', ports) self.assertIn('9001/tcp:[{127.0.0.2 ', ports) self.assertNotIn('7001/tcp', ports)