diff options
| author | Dave Hibberd <hibby@debian.org> | 2024-10-26 00:44:52 +0100 |
|---|---|---|
| committer | Dave Hibberd <hibby@debian.org> | 2024-10-26 00:44:52 +0100 |
| commit | a07fb6c62db75414a4a3b04006f52e0efb0c450c (patch) | |
| tree | a7bb8c65a89fde5b1a1a1c49e175d7f75aaf4867 /tests/unit | |
| parent | c891fdbe99e3d4b3ec76f1a221839702bef9a787 (diff) | |
New upstream version 20241025upstream/20241025
Diffstat (limited to 'tests/unit')
| -rw-r--r-- | tests/unit/__pycache__/test_chirp_common.cpython-310-pytest-7.1.3.pyc | bin | 31415 -> 31643 bytes | |||
| -rw-r--r-- | tests/unit/__pycache__/test_csv.cpython-310-pytest-7.1.3.pyc | bin | 8715 -> 10108 bytes | |||
| -rw-r--r-- | tests/unit/__pycache__/test_wxui_radiothread.cpython-310-pytest-7.1.3.pyc | bin | 7345 -> 7151 bytes | |||
| -rw-r--r-- | tests/unit/test_chirp_common.py | 8 | ||||
| -rw-r--r-- | tests/unit/test_wxui_radiothread.py | 12 |
5 files changed, 8 insertions, 12 deletions
diff --git a/tests/unit/__pycache__/test_chirp_common.cpython-310-pytest-7.1.3.pyc b/tests/unit/__pycache__/test_chirp_common.cpython-310-pytest-7.1.3.pyc Binary files differindex b00f0d3..cff5622 100644 --- a/tests/unit/__pycache__/test_chirp_common.cpython-310-pytest-7.1.3.pyc +++ b/tests/unit/__pycache__/test_chirp_common.cpython-310-pytest-7.1.3.pyc diff --git a/tests/unit/__pycache__/test_csv.cpython-310-pytest-7.1.3.pyc b/tests/unit/__pycache__/test_csv.cpython-310-pytest-7.1.3.pyc Binary files differindex 69b0838..3ba6d7a 100644 --- a/tests/unit/__pycache__/test_csv.cpython-310-pytest-7.1.3.pyc +++ b/tests/unit/__pycache__/test_csv.cpython-310-pytest-7.1.3.pyc diff --git a/tests/unit/__pycache__/test_wxui_radiothread.cpython-310-pytest-7.1.3.pyc b/tests/unit/__pycache__/test_wxui_radiothread.cpython-310-pytest-7.1.3.pyc Binary files differindex 898259a..68805b0 100644 --- a/tests/unit/__pycache__/test_wxui_radiothread.cpython-310-pytest-7.1.3.pyc +++ b/tests/unit/__pycache__/test_wxui_radiothread.cpython-310-pytest-7.1.3.pyc diff --git a/tests/unit/test_chirp_common.py b/tests/unit/test_chirp_common.py index 458a126..ea3bcf8 100644 --- a/tests/unit/test_chirp_common.py +++ b/tests/unit/test_chirp_common.py @@ -503,6 +503,11 @@ class TestStepFunctions(base.BaseTest): self.assertEqual(2.5, chirp_common.required_step(self._005[0], allowed=[2.5])) + def test_required_step_finds_radio_specific(self): + # Make sure we find a radio-specific step, 10Hz in this case + self.assertEqual(0.01, chirp_common.required_step( + 146000010, allowed=[5.0, 10.0, 0.01, 20.0])) + def test_required_step_fail(self): self.assertRaises(errors.InvalidDataError, chirp_common.required_step, @@ -771,9 +776,6 @@ class TestOverrideRules(base.BaseTest): 'BTECH_MURS-V2', 'Radioddity_DB25-G', 'Retevis_RB17P', - 'Baofeng_UV-17ProGPS', - 'Baofeng_5RM', - 'Baofeng_K5-Plus', ] def _test_radio_override_immutable_policy(self, rclass): diff --git a/tests/unit/test_wxui_radiothread.py b/tests/unit/test_wxui_radiothread.py index 0277034..18d08b5 100644 --- a/tests/unit/test_wxui_radiothread.py +++ b/tests/unit/test_wxui_radiothread.py @@ -164,15 +164,9 @@ class TestClone(base.BaseTest): # be visible in the model box. for rclass in [x for x in directory.DRV_TO_RADIO.values() if issubclass(x, chirp_common.DetectableInterface)]: - labels = [] - for child_rclass in rclass.detected_models(include_self=False): - label = clone.detected_value(rclass, child_rclass) - self.assertNotEqual('', label) - labels.append(label) - if labels: - label = '%s (+ %s)' % (rclass.MODEL, ','.join(labels)) - self.assertLessEqual(len(label), 32, - 'Label %r is too long' % label) + label = clone.get_model_label(rclass) + self.assertLessEqual(len(label), 32, + 'Label %r is too long' % label) class TestException(Exception): |
