/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_repository.py

  • Committer: Robert Collins
  • Date: 2008-01-09 00:51:01 UTC
  • mto: This revision was merged to the branch mainline in revision 3172.
  • Revision ID: robertc@robertcollins.net-20080109005101-mmpiihes7sw3uzr5
Add a test to Repository.deserialise_inventory that the resulting ivnentory is the one asked for, and update relevant tests. Also tweak the model 1 to 2 regenerate inventories logic to use the revision trees parent marker which is more accurate in some cases.

Show diffs side-by-side

added added

removed removed

Lines of Context:
398
398
        # Arguably, the deserialise_inventory should detect a mismatch, and
399
399
        # raise an error, rather than silently using one revision_id over the
400
400
        # other.
401
 
        inv = repo.deserialise_inventory('test-rev-id', inv_xml)
 
401
        self.assertRaises(AssertionError, repo.deserialise_inventory,
 
402
            'test-rev-id', inv_xml)
 
403
        inv = repo.deserialise_inventory('other-rev-id', inv_xml)
402
404
        self.assertEqual('other-rev-id', inv.root.revision)
403
405
 
404
406