summaryrefslogtreecommitdiff
path: root/tests/test_detect.py
diff options
context:
space:
mode:
authorDave Hibberd <hibby@debian.org>2024-02-24 13:47:31 +0000
committerDave Hibberd <hibby@debian.org>2024-02-24 13:47:31 +0000
commit22d82ba3c0d6bd591c135290d88adcc2414ba588 (patch)
tree98dacd9f46560513d2869207b7f13a8ca9294ba2 /tests/test_detect.py
parente5819ceb55106d4b9b8d34d4d4e031b2a895b760 (diff)
parentfc438e6a84402e621877f6c30097442af46f122b (diff)
Update upstream source from tag 'upstream/20240224'
Update to upstream version '20240224' with Debian dir f7af8ad341f9d73e94489b1e0a1b6e721fc7f61d
Diffstat (limited to 'tests/test_detect.py')
-rw-r--r--tests/test_detect.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/test_detect.py b/tests/test_detect.py
index 5a94cb9..8acad47 100644
--- a/tests/test_detect.py
+++ b/tests/test_detect.py
@@ -5,12 +5,17 @@ from unittest import mock
import pytest
from chirp import directory
+from chirp import logger
from tests import base
class TestCaseDetect(base.DriverTest):
def test_detect(self):
- radio = directory.get_radio_by_image(self.TEST_IMAGE)
+ with logger.log_history(logging.WARNING, 'chirp.drivers') as history:
+ radio = directory.get_radio_by_image(self.TEST_IMAGE)
+ self.assertEqual([], history.get_history(),
+ 'Drivers should not log warnings/errors for '
+ 'good images')
if hasattr(radio, '_orig_rclass'):
radio = radio._orig_rclass(self.TEST_IMAGE)
if isinstance(self.radio, radio.__class__):