test: py: Fix log level restore in SimpleTestMethods()
The SimpleTestMethods() function tests that incorrect calls to the
Camera.acquire() method raise an exception. Before doing so, it sets the
log level for the Camera category to FATAL, in order to avoid showing
misleading errors in the test log, and then restores the log level to
ERROR after running the test. ERROR is however not the default log
level. Restore the log level to INFO instead, in order to avoid losing
log messages in subsequent tests.
Fixes: 06cb7130c4
("py: Add unittests.py")
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
This commit is contained in:
parent
7ff6fd9774
commit
876730d805
1 changed files with 1 additions and 1 deletions
|
@ -66,7 +66,7 @@ class SimpleTestMethods(BaseTestCase):
|
|||
libcam.log_set_level('Camera', 'FATAL')
|
||||
with self.assertRaises(RuntimeError):
|
||||
cam.acquire()
|
||||
libcam.log_set_level('Camera', 'ERROR')
|
||||
libcam.log_set_level('Camera', 'INFO')
|
||||
|
||||
cam.release()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue