summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ideasonboard.com>2023-05-30 15:01:29 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2023-05-30 18:29:08 +0300
commit9506da142b5de012d2b98072273b223b77ba4439 (patch)
treeb26eca93db0a297804a17fca569a57376edba89a /test
parentb9ecd85ed1fee2e9d715368b24592ad3009131d8 (diff)
py: Fix CameraManager.version property
The current CameraManager.version doesn't work at all (raises a TypeError), as that's not how you use expose C++ static methods as Python class methods. Fix it. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'test')
-rwxr-xr-xtest/py/unittests.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/py/unittests.py b/test/py/unittests.py
index 6dea80fc..90b04330 100755
--- a/test/py/unittests.py
+++ b/test/py/unittests.py
@@ -68,6 +68,10 @@ class SimpleTestMethods(BaseTestCase):
# I expected EBUSY, but looks like double release works fine
self.assertZero(ret)
+ def test_version(self):
+ cm = libcam.CameraManager.singleton()
+ self.assertIsInstance(cm.version, str)
+
class CameraTesterBase(BaseTestCase):
cm: typing.Any