diff options
Diffstat (limited to 'test/varlink/test_system.py')
-rw-r--r-- | test/varlink/test_system.py | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/varlink/test_system.py b/test/varlink/test_system.py new file mode 100644 index 000000000..6180d2068 --- /dev/null +++ b/test/varlink/test_system.py @@ -0,0 +1,21 @@ +import unittest +from varlink import (Client, VarlinkError) + + +address = "unix:/run/podman/io.projectatomic.podman" +client = Client(address=address) + +class SystemAPI(unittest.TestCase): + def test_ping(self): + podman = client.open("io.projectatomic.podman") + response = podman.Ping() + self.assertEqual("OK", response["ping"]["message"]) + + def test_GetVersion(self): + podman = client.open("io.projectatomic.podman") + response = podman.GetVersion() + for k in ["version", "go_version", "built", "os_arch"]: + self.assertTrue(k in response["version"].keys()) + +if __name__ == '__main__': + unittest.main() |