summaryrefslogtreecommitdiff
path: root/gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py
diff options
context:
space:
mode:
authorSebastian Koslowski <koslowski@kit.edu>2015-07-27 16:45:09 +0200
committerSebastian Koslowski <koslowski@kit.edu>2015-07-27 16:58:44 +0200
commit623f96357c79b36dc49f66dee56284d5f41a822e (patch)
tree876e1b2f9a7aad9ec6afdbc978d3ede056242f93 /gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py
parentf8a9f9fb9939799228ef38deab68c71a44acd324 (diff)
runtime: stop catching errors from primitive_connect in connect decorator
Diffstat (limited to 'gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py')
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py b/gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py
index 50b1562f3a..a079f8de70 100644
--- a/gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py
+++ b/gnuradio-runtime/python/gnuradio/gr/qa_hier_block2.py
@@ -66,14 +66,12 @@ class test_hier_block2(gr_unittest.TestCase):
self.assertEqual(expected, self.call_log)
def test_005(self):
- with self.assertRaises(ValueError) as c:
+ with self.assertRaises(ValueError):
self.multi((self.Block(), 5))
- self.assertIsInstance(c.exception, ValueError)
def test_006(self):
- with self.assertRaises(ValueError) as c:
- self.multi(self.Block(), (self.Block(), 5, 5))
- self.assertIsInstance(c.exception, ValueError)
+ with self.assertRaises(ValueError):
+ self.multi(self.Block(), (5, 5))
def test_007(self):
b1, b2 = self.Block(), self.Block()
@@ -85,6 +83,10 @@ class test_hier_block2(gr_unittest.TestCase):
self.opt((b1, "in"), (b2, "out"))
self.assertEqual([(b1, "in", b2, "out")], self.call_log)
+ def test_009(self):
+ with self.assertRaises(ValueError):
+ self.multi(self.Block(), 5)
+
if __name__ == '__main__':
gr_unittest.run(test_hier_block2, "test_hier_block2.xml")