summaryrefslogtreecommitdiff
path: root/gr-uhd/python/uhd
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2021-01-06 16:45:17 +0100
committerMarcus Müller <marcus@hostalia.de>2021-01-07 21:43:34 +0100
commit05f09299f3ca1afe5c7965b5407bd23353783067 (patch)
tree294084769445888d63ce0a95ba40a804e5b9aa1f /gr-uhd/python/uhd
parent0f1ec604f758e28d788ad71283236928d2d82300 (diff)
uhd: Fix unit test
The qa_uhd.py test has been broken for a long time. Now fixed. Signed-off-by: Martin Braun <martin@gnuradio.org>
Diffstat (limited to 'gr-uhd/python/uhd')
-rw-r--r--gr-uhd/python/uhd/qa_uhd.py12
1 files changed, 5 insertions, 7 deletions
diff --git a/gr-uhd/python/uhd/qa_uhd.py b/gr-uhd/python/uhd/qa_uhd.py
index d87ab77c42..65b50d794b 100644
--- a/gr-uhd/python/uhd/qa_uhd.py
+++ b/gr-uhd/python/uhd/qa_uhd.py
@@ -6,12 +6,12 @@
#
# SPDX-License-Identifier: GPL-3.0-or-later
#
-#
-
+"""
+gr-uhd sanity checking
+"""
from gnuradio import gr, gr_unittest, uhd
-
class test_uhd(gr_unittest.TestCase):
def setUp(self):
@@ -37,11 +37,9 @@ class test_uhd(gr_unittest.TestCase):
"""
Try to manipulate the stream args channels for proper swig'ing checks.
"""
- # FIXME: stream_args_t.channels.append does not work due to copy operation of STL vectors
- # Needs to either change API, remove QA test, or somehow remap append()
+ # FYI: stream_args_t.channels.append does not work due to copy operation of STL vectors
sa = uhd.stream_args_t()
- sa.channels.append(1)
- sa.channels.append(0)
+ sa.channels = [1, 0]
print(sa.channels)
self.assertEqual(len(sa.channels), 2)
self.assertEqual(sa.channels[0], 1)