[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] [gnuradio] 44/46: zeromq: updates to qa code to wait f
From: |
git |
Subject: |
[Commit-gnuradio] [gnuradio] 44/46: zeromq: updates to qa code to wait for completion and pass. |
Date: |
Fri, 16 May 2014 19:37:17 +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 f4a0034532eefbeeaa6fd0d05f305463f106e50b
Author: Tom Rondeau <address@hidden>
Date: Fri May 16 14:02:06 2014 -0400
zeromq: updates to qa code to wait for completion and pass.
---
gr-zeromq/python/zeromq/qa_zeromq_pub.py | 3 ++-
gr-zeromq/python/zeromq/qa_zeromq_pushpull.py | 8 ++++++--
gr-zeromq/python/zeromq/qa_zeromq_reqrep.py | 8 ++++++--
3 files changed, 14 insertions(+), 5 deletions(-)
diff --git a/gr-zeromq/python/zeromq/qa_zeromq_pub.py
b/gr-zeromq/python/zeromq/qa_zeromq_pub.py
index 8a4d491..6f08aa5 100755
--- a/gr-zeromq/python/zeromq/qa_zeromq_pub.py
+++ b/gr-zeromq/python/zeromq/qa_zeromq_pub.py
@@ -43,7 +43,8 @@ class qa_zeromq_pub (gr_unittest.TestCase):
self.probe_manager = zeromq.probe_manager()
self.probe_manager.add_socket("tcp://127.0.0.1:5555", 'float32',
self.recv_data)
self.tb.run()
- self.assertEqual(self.rx_data, src_data)
+ self.probe_manager.watcher()
+ self.assertFloatTuplesAlmostEqual(self.rx_data, src_data)
def recv_data (self, data):
self.rx_data = data
diff --git a/gr-zeromq/python/zeromq/qa_zeromq_pushpull.py
b/gr-zeromq/python/zeromq/qa_zeromq_pushpull.py
index 56f0cb6..0b732c9 100755
--- a/gr-zeromq/python/zeromq/qa_zeromq_pushpull.py
+++ b/gr-zeromq/python/zeromq/qa_zeromq_pushpull.py
@@ -21,6 +21,7 @@
#
from gnuradio import gr, gr_unittest, blocks, zeromq
+import time
class qa_zeromq_pushpull (gr_unittest.TestCase):
@@ -39,8 +40,11 @@ class qa_zeromq_pushpull (gr_unittest.TestCase):
sink = blocks.vector_sink_f(vlen)
self.tb.connect(src, zeromq_push_sink)
self.tb.connect(zeromq_pull_source, sink)
- self.tb.run ()
- self.assertEqual(sink.data(), src_data)
+ self.tb.start()
+ time.sleep(0.25)
+ self.tb.stop()
+ self.tb.wait()
+ self.assertFloatTuplesAlmostEqual(sink.data(), src_data)
if __name__ == '__main__':
gr_unittest.run(qa_zeromq_pushpull)
diff --git a/gr-zeromq/python/zeromq/qa_zeromq_reqrep.py
b/gr-zeromq/python/zeromq/qa_zeromq_reqrep.py
index 337f285..3329add 100755
--- a/gr-zeromq/python/zeromq/qa_zeromq_reqrep.py
+++ b/gr-zeromq/python/zeromq/qa_zeromq_reqrep.py
@@ -24,6 +24,7 @@
from gnuradio import gr, gr_unittest
from gnuradio import blocks, zeromq
from gnuradio import eng_notation
+import time
class qa_zeromq_reqrep (gr_unittest.TestCase):
@@ -42,8 +43,11 @@ class qa_zeromq_reqrep (gr_unittest.TestCase):
sink = blocks.vector_sink_f(vlen)
self.tb.connect(src, zeromq_rep_sink)
self.tb.connect(zeromq_req_source, sink)
- self.tb.run ()
- self.assertEqual(sink.data(), src_data)
+ self.tb.start()
+ time.sleep(0.25)
+ self.tb.stop()
+ self.tb.wait()
+ self.assertFloatTuplesAlmostEqual(sink.data(), src_data)
if __name__ == '__main__':
gr_unittest.run(qa_zeromq_reqrep)
- [Commit-gnuradio] [gnuradio] 31/46: zeromq: Add missing timeout and blocking parameters and polling, (continued)
- [Commit-gnuradio] [gnuradio] 31/46: zeromq: Add missing timeout and blocking parameters and polling, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 25/46: zeromq: Add grc examples, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 38/46: zeromq: Don't call context close as it is not available in zmq 2, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 37/46: zeromq: Change the value of the poll timeout according to the zmq version. Must be in microseconds for version 2 and below and in milliseconds for version 3 and above., git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 35/46: zeromq: Add qa code, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 36/46: zeromq: Change string of test name, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 02/46: zeromq: initial surgery to add to master build, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 46/46: Merge branch 'zeromq', git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 40/46: zeromq: Remove blocking Add timeout in xml, fix doxygen, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 39/46: Add sub_source block and fix pub_sink, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 44/46: zeromq: updates to qa code to wait for completion and pass.,
git <=
- [Commit-gnuradio] [gnuradio] 45/46: zeromq: add missing vlen parameter in ports, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 42/46: zeromq: fixing up QA code for vlen, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 43/46: zeromq: update examples and install, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 41/46: zeromq: temporarily removing QA test output to XML, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 23/46: zeromq: cleanup docs and examples, git, 2014/05/16
- [Commit-gnuradio] [gnuradio] 01/46: Initial import of gr-zmqblocks OOT project as-is, prior to rework for in-tree, git, 2014/05/16