Imported Upstream version 3.2.2
[debian/gnuradio] / gnuradio-core / src / python / gnuradio / gr / qa_unpack_k_bits.py
index f8c21b2ccf240930dff908ff4a35cac4ee2f9ef1..edb263ade6eef7853a326348eb565f65863c8124 100755 (executable)
@@ -6,7 +6,7 @@
 # 
 # GNU Radio is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
+# the Free Software Foundation; either version 3, or (at your option)
 # any later version.
 # 
 # GNU Radio is distributed in the hope that it will be useful,
@@ -26,10 +26,10 @@ import random
 class test_unpack(gr_unittest.TestCase):
 
     def setUp(self):
-        self.fg = gr.flow_graph ()
+        self.tb = gr.top_block ()
 
     def tearDown(self):
-        self.fg = None
+        self.tb = None
 
     def test_001(self):
         src_data =         (1,0,1,1,0,1,1,0)
@@ -37,8 +37,8 @@ class test_unpack(gr_unittest.TestCase):
         src = gr.vector_source_b(src_data,False)
         op = gr.unpack_k_bits_bb(1)
         dst = gr.vector_sink_b()
-        self.fg.connect(src, op, dst)
-        self.fg.run()
+        self.tb.connect(src, op, dst)
+        self.tb.run()
         self.assertEqual(expected_results, dst.data())
 
     def test_002(self):
@@ -47,8 +47,8 @@ class test_unpack(gr_unittest.TestCase):
         src = gr.vector_source_b(src_data,False)
         op = gr.unpack_k_bits_bb(2)
         dst = gr.vector_sink_b()
-        self.fg.connect(src, op, dst)
-        self.fg.run()
+        self.tb.connect(src, op, dst)
+        self.tb.run()
         self.assertEqual(expected_results, dst.data())