[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] [gnuradio] 03/04: runtime: update message port qa to a
From: |
git |
Subject: |
[Commit-gnuradio] [gnuradio] 03/04: runtime: update message port qa to account for new system port |
Date: |
Tue, 29 Apr 2014 17:42:12 +0000 (UTC) |
This is an automated email from the git hooks/post-receive script.
jcorgan pushed a commit to branch master
in repository gnuradio.
commit dd17d80c5b0c81bddf71c802dc47310a61ff4aa3
Author: Tim O'Shea <address@hidden>
Date: Mon Apr 28 11:59:50 2014 -0400
runtime: update message port qa to account for new system port
---
gr-blocks/python/blocks/qa_pdu.py | 2 +-
gr-digital/python/digital/qa_header_payload_demux.py | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/gr-blocks/python/blocks/qa_pdu.py
b/gr-blocks/python/blocks/qa_pdu.py
index 81cd8cf..5a29e04 100755
--- a/gr-blocks/python/blocks/qa_pdu.py
+++ b/gr-blocks/python/blocks/qa_pdu.py
@@ -48,7 +48,7 @@ class test_pdu(gr_unittest.TestCase):
# Test that the right number of ports exist.
pi = snk3.message_ports_in()
po = snk3.message_ports_out()
- self.assertEqual(pmt.length(pi), 0)
+ self.assertEqual(pmt.length(pi), 1) #system port is defined
automatically
self.assertEqual(pmt.length(po), 1)
self.tb.connect(src, snk)
diff --git a/gr-digital/python/digital/qa_header_payload_demux.py
b/gr-digital/python/digital/qa_header_payload_demux.py
index 2bacf72..0b754fe 100755
--- a/gr-digital/python/digital/qa_header_payload_demux.py
+++ b/gr-digital/python/digital/qa_header_payload_demux.py
@@ -73,7 +73,7 @@ class qa_header_payload_demux (gr_unittest.TestCase):
hpd = digital.header_payload_demux(
len(header), 1, 0, "frame_len", "detect", False, gr.sizeof_float
)
- self.assertEqual(pmt.length(hpd.message_ports_in()), 1)
+ self.assertEqual(pmt.length(hpd.message_ports_in()), 2) #extra system
port defined for you
header_sink = blocks.vector_sink_f()
payload_sink = blocks.vector_sink_f()
@@ -157,7 +157,7 @@ class qa_header_payload_demux (gr_unittest.TestCase):
True, # Output symbols (not items)
gr.sizeof_float # Bytes per item
)
- self.assertEqual(pmt.length(hpd.message_ports_in()), 1)
+ self.assertEqual(pmt.length(hpd.message_ports_in()), 2) #extra system
port defined for you
header_sink = blocks.vector_sink_f(items_per_symbol)
payload_sink = blocks.vector_sink_f(items_per_symbol)
self.tb.connect(data_src, (hpd, 0))
@@ -248,7 +248,7 @@ class qa_header_payload_demux (gr_unittest.TestCase):
samp_rate=sampling_rate,
special_tags=('rx_freq',),
)
- self.assertEqual(pmt.length(hpd.message_ports_in()), 1)
+ self.assertEqual(pmt.length(hpd.message_ports_in()), 2) #extra system
port defined for you
header_sink = blocks.vector_sink_f()
payload_sink = blocks.vector_sink_f()
self.tb.connect(data_src, (hpd, 0))