~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: John Arbash Meinel
  • Date: 2012-09-19 07:58:27 UTC
  • mfrom: (6437.63.9 2.5)
  • mto: This revision was merged to the branch mainline in revision 6563.
  • Revision ID: john@arbash-meinel.com-20120919075827-36b2b042kiaps0d3
Merge bzr-2.5.2 into trunk to get the fixes for ConnectionReset.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
 
22
22
from bzrlib import (
23
23
    errors,
24
 
    osutils,
25
24
    revision as _mod_revision,
26
 
    tests,
27
25
    )
28
26
from bzrlib.inventory import (
29
27
    Inventory,
475
473
        # large hammer, this is a particularly sensitive area of code, so the
476
474
        # extra assurance is well worth it.
477
475
        tree._validate()
478
 
        osutils.rmtree('tree')
 
476
        # If tree.branch is remote
 
477
        if tree.user_url != tree.branch.user_url:
 
478
            # We have a lightweight checkout, delete both locations
 
479
            tree.branch.bzrdir.root_transport.delete_tree('.')
 
480
        tree.bzrdir.root_transport.delete_tree('.')
479
481
 
480
482
    def test_no_parents_just_root(self):
481
483
        """Test doing an empty commit - no parent, set a root only."""