~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/workingtree_implementations/test_parents.py

  • Committer: Mark Hammond
  • Date: 2008-08-12 13:07:00 UTC
  • mto: (3691.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 3692.
  • Revision ID: mhammond@skippinet.com.au-20080812130700-05ohg06353nxg22q
eagerly unlock the result_basis to prevent handles staying open.

Show diffs side-by-side

added added

removed removed

Lines of Context:
337
337
        # the delta.
338
338
        result_basis = tree.basis_tree()
339
339
        result_basis.lock_read()
340
 
        self.addCleanup(result_basis.unlock)
341
 
        self.assertEqual(expected_inventory, result_basis.inventory)
 
340
        try:
 
341
            self.assertEqual(expected_inventory, result_basis.inventory)
 
342
        finally:
 
343
            result_basis.unlock()
342
344
 
343
345
    def make_inv_delta(self, old, new):
344
346
        """Make an inventory delta from two inventories."""