~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/selftest/test_xml.py

  • Committer: Martin Pool
  • Date: 2005-09-06 07:26:13 UTC
  • Revision ID: mbp@sourcefrog.net-20050906072613-1a4a18769aaaa3eb
- add xml round-trip test for revisions

- fix up __eq__ method for Revision

Show diffs side-by-side

added added

removed removed

Lines of Context:
129
129
        serializer_v5.write_inventory(inv, outp)
130
130
        inv2 = serializer_v5.read_inventory(StringIO(outp.getvalue()))
131
131
        self.assertEqual(inv, inv2)
 
132
 
 
133
    def test_repack_revision_5(self):
 
134
        inp = StringIO(_revision_v5)
 
135
        rev = serializer_v5.read_revision(inp)
 
136
        outp = StringIO()
 
137
        serializer_v5.write_revision(rev, outp)
 
138
        rev2 = serializer_v5.read_revision(StringIO(outp.getvalue()))
 
139
        self.assertEqual(rev, rev2)
 
140