BIND 10 trac2855, updated. 5d90a73da81fcd5f908b650663166124ca76bea0 [2855] Make the response a tuple

BIND 10 source code commits bind10-changes at lists.isc.org
Sun Jun 23 20:44:27 UTC 2013


The branch, trac2855 has been updated
       via  5d90a73da81fcd5f908b650663166124ca76bea0 (commit)
      from  b7c2bcca4fb95fbaf48835fcebd45b3934f1ad74 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 5d90a73da81fcd5f908b650663166124ca76bea0
Author: Mukund Sivaraman <muks at isc.org>
Date:   Mon Jun 24 02:14:09 2013 +0530

    [2855] Make the response a tuple
    
    This is for some kind of compatibility with future tickets, but the
    exact format of the response list is currently not decided.

-----------------------------------------------------------------------

Summary of changes:
 src/lib/python/isc/memmgr/builder.py             |    2 +-
 src/lib/python/isc/memmgr/tests/builder_tests.py |    5 ++++-
 2 files changed, 5 insertions(+), 2 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/lib/python/isc/memmgr/builder.py b/src/lib/python/isc/memmgr/builder.py
index f01f830..2e8b71c 100644
--- a/src/lib/python/isc/memmgr/builder.py
+++ b/src/lib/python/isc/memmgr/builder.py
@@ -91,7 +91,7 @@ class MemorySegmentBuilder:
                         # notified. Instead return this in the response
                         # queue.
                         with self._lock:
-                            self._response_queue.append('bad_command')
+                            self._response_queue.append(('bad_command',))
                             # In this case, we do not notify the main
                             # thread about a response on the socket, as
                             # we quit the main loop here anyway (and any
diff --git a/src/lib/python/isc/memmgr/tests/builder_tests.py b/src/lib/python/isc/memmgr/tests/builder_tests.py
index 2b21337..230f396 100644
--- a/src/lib/python/isc/memmgr/tests/builder_tests.py
+++ b/src/lib/python/isc/memmgr/tests/builder_tests.py
@@ -73,7 +73,10 @@ class TestMemorySegmentBuilder(unittest.TestCase):
         with self._builder_lock:
             self.assertEqual(len(self._builder_command_queue), 0)
             self.assertEqual(len(self._builder_response_queue), 1)
-            self.assertListEqual(self._builder_response_queue, ['bad_command'])
+
+            response = self._builder_response_queue[0]
+            self.assertTrue(isinstance(response, tuple))
+            self.assertTupleEqual(response, ('bad_command',))
             self._builder_response_queue.clear()
 
     def test_shutdown(self):



More information about the bind10-changes mailing list