summaryrefslogtreecommitdiff
path: root/gnuradio-core/src/python
diff options
context:
space:
mode:
Diffstat (limited to 'gnuradio-core/src/python')
-rwxr-xr-xgnuradio-core/src/python/gnuradio/gr/qa_tag_utils.py12
1 files changed, 8 insertions, 4 deletions
diff --git a/gnuradio-core/src/python/gnuradio/gr/qa_tag_utils.py b/gnuradio-core/src/python/gnuradio/gr/qa_tag_utils.py
index d0c2f2f221..ca1184979b 100755
--- a/gnuradio-core/src/python/gnuradio/gr/qa_tag_utils.py
+++ b/gnuradio-core/src/python/gnuradio/gr/qa_tag_utils.py
@@ -22,7 +22,11 @@
from gnuradio import gr, gr_unittest
import tag_utils
-import pmt
+
+try:
+ import pmt_swig as pmt
+except ImportError:
+ import pmt
class test_tag_utils (gr_unittest.TestCase):
@@ -36,9 +40,9 @@ class test_tag_utils (gr_unittest.TestCase):
def test_001(self):
t = gr.gr_tag_t()
t.offset = 10
- t.key = pmt.string_to_symbol('key')
- t.value = pmt.from_long(23)
- t.srcid = pmt.from_bool(False)
+ t.key = pmt.pmt_string_to_symbol('key')
+ t.value = pmt.pmt_from_long(23)
+ t.srcid = pmt.pmt_from_bool(False)
pt = tag_utils.tag_to_python(t)
self.assertEqual(pt.key, 'key')
self.assertEqual(pt.value, 23)