diff options
author | Tom Rondeau <tom@trondeau.com> | 2014-07-07 12:18:00 -0400 |
---|---|---|
committer | Tom Rondeau <tom@trondeau.com> | 2014-07-07 12:18:00 -0400 |
commit | 597b93798a804cde1783d6d2ab53b348d57c44cd (patch) | |
tree | b65e73bb0de634ff5d209b15971ebdabf369a45c /gr-blocks/python/blocks/qa_python_message_passing.py | |
parent | 1151e5502ccd440ebd89599cf7e4be4fb5ed8334 (diff) |
Removing trailing/extra whitespaces before release.
We should be more careful about letting these into the code in the future. In emacs, we can use (add-hook 'before-save-hook 'delete-trailing-whitespace).
Diffstat (limited to 'gr-blocks/python/blocks/qa_python_message_passing.py')
-rw-r--r-- | gr-blocks/python/blocks/qa_python_message_passing.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/gr-blocks/python/blocks/qa_python_message_passing.py b/gr-blocks/python/blocks/qa_python_message_passing.py index e391c5f952..7bb5fbe10e 100644 --- a/gr-blocks/python/blocks/qa_python_message_passing.py +++ b/gr-blocks/python/blocks/qa_python_message_passing.py @@ -69,7 +69,7 @@ class message_consumer(gr.sync_block): self.msg_list.append(pmt.from_long(pmt.to_long(msg))) class test_python_message_passing(gr_unittest.TestCase): - + def setUp(self): self.tb = gr.top_block() @@ -90,17 +90,17 @@ class test_python_message_passing(gr_unittest.TestCase): src = blocks.vector_source_f(src_data, False) msg_gen = message_generator(msg_list, msg_interval) msg_cons = message_consumer() - + # Connect vector source to message gen self.tb.connect(src, msg_gen) - + # Connect message generator to message consumer self.tb.msg_connect(msg_gen, 'out_port', msg_cons, 'in_port') # Verify that the messgae port query functions work self.assertEqual(pmt.to_python(msg_gen.message_ports_out())[0], 'out_port') self.assertEqual('in_port' in pmt.to_python(msg_cons.message_ports_in()), True) - + # Run to verify message passing self.tb.start() @@ -108,13 +108,13 @@ class test_python_message_passing(gr_unittest.TestCase): while msg_gen.msg_ctr < num_msgs: time.sleep(0.5) self.tb.stop() - self.tb.wait() - + self.tb.wait() + # Verify that the message consumer got all the messages self.assertEqual(num_msgs, len(msg_cons.msg_list)) for i in range(num_msgs): self.assertTrue(pmt.equal(msg_list[i], msg_cons.msg_list[i])) - + if __name__ == '__main__': - gr_unittest.run(test_python_message_passing, + gr_unittest.run(test_python_message_passing, 'test_python_message_passing.xml') |