Rev 2616: Delimiting of multiple reference lists is by \t in http://people.ubuntu.com/~robertc/baz2.0/repository

Robert Collins robertc at robertcollins.net
Fri Jul 13 09:24:28 BST 2007


At http://people.ubuntu.com/~robertc/baz2.0/repository

------------------------------------------------------------
revno: 2616
revision-id: robertc at robertcollins.net-20070713082425-2zkkb3e67a94564e
parent: robertc at robertcollins.net-20070713081858-ny0sze3ih9xabox5
committer: Robert Collins <robertc at robertcollins.net>
branch nick: repository
timestamp: Fri 2007-07-13 18:24:25 +1000
message:
  Delimiting of multiple reference lists is by \t
modified:
  bzrlib/tests/test_index.py     test_index.py-20070712131115-lolkarso50vjr64s-2
=== modified file 'bzrlib/tests/test_index.py'
--- a/bzrlib/tests/test_index.py	2007-07-13 08:18:58 +0000
+++ b/bzrlib/tests/test_index.py	2007-07-13 08:24:25 +0000
@@ -116,6 +116,17 @@
             "key\0\x0051\r38\0data\n"
             "\n", contents)
 
+    def test_multiple_reference_lists_are_tab_delimited(self):
+        builder = GraphIndexBuilder(reference_lists=2)
+        builder.add_node('reference', ([], []), 'data')
+        builder.add_node('key', (['reference'], ['reference']), 'data')
+        stream = builder.finish()
+        contents = stream.read()
+        self.assertEqual("Bazaar Graph Index 1\nnode_ref_lists=2\n"
+            "reference\0\0\t\0data\n"
+            "key\0\x0038\t38\0data\n"
+            "\n", contents)
+
     def test_add_node_bad_key(self):
         builder = GraphIndexBuilder()
         for bad_char in '\t\n\x0b\x0c\r\x00 ':




More information about the bazaar-commits mailing list