summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJhon Honce <jhonce@redhat.com>2021-08-19 14:19:45 -0700
committerJhon Honce <jhonce@redhat.com>2021-08-19 14:19:45 -0700
commitfd32c73e3ab8c2fcd691172574fec89547e256ce (patch)
treec04edf1b50a961e86f074d9d9216a6b6dec9d314 /test
parentf988cfe1463f795f51f64e0887ba9dd9fe85b23d (diff)
downloadpodman-fd32c73e3ab8c2fcd691172574fec89547e256ce.tar.gz
podman-fd32c73e3ab8c2fcd691172574fec89547e256ce.tar.bz2
podman-fd32c73e3ab8c2fcd691172574fec89547e256ce.zip
Update /version endpoint to add components
* Include OCI and conmon information as components Fixes #11227 Signed-off-by: Jhon Honce <jhonce@redhat.com>
Diffstat (limited to 'test')
-rw-r--r--test/apiv2/python/rest_api/test_v2_0_0_system.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/apiv2/python/rest_api/test_v2_0_0_system.py b/test/apiv2/python/rest_api/test_v2_0_0_system.py
index 3628b5af1..3dfd08525 100644
--- a/test/apiv2/python/rest_api/test_v2_0_0_system.py
+++ b/test/apiv2/python/rest_api/test_v2_0_0_system.py
@@ -70,6 +70,15 @@ class SystemTestCase(APITestCase):
r = requests.get(self.uri("/version"))
self.assertEqual(r.status_code, 200, r.text)
+ body = r.json()
+ names = [d.get("Name", "") for d in body["Components"]]
+
+ self.assertIn("Conmon", names)
+ for n in names:
+ if n.startswith("OCI Runtime"):
+ oci_name = n
+ self.assertIsNotNone(oci_name, "OCI Runtime not found in version components.")
+
def test_df(self):
r = requests.get(self.podman_url + "/v1.40/system/df")
self.assertEqual(r.status_code, 200, r.text)