~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: Robert Collins
  • Date: 2010-04-08 04:34:03 UTC
  • mfrom: (5138 +trunk)
  • mto: This revision was merged to the branch mainline in revision 5139.
  • Revision ID: robertc@robertcollins.net-20100408043403-56z0d07vdqrx7f3t
Update bugfix for 528114 to trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
60
60
 
61
61
    def set_dirs_readonly(self, basedir):
62
62
        """Set all directories readonly, and have it cleanup on test exit."""
 
63
        self.addCleanup(self._set_all_dirs, basedir, readonly=False)
63
64
        self._set_all_dirs(basedir, readonly=True)
64
65
 
65
 
        def cleanup():
66
 
            self._set_all_dirs(basedir, readonly=False)
67
 
 
68
 
        self.addCleanup(cleanup)
69
 
 
70
66
    def create_basic_tree(self):
71
67
        tree = self.make_branch_and_tree('tree')
72
68
        self.build_tree(['tree/a', 'tree/b/', 'tree/b/c'])