~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bzrdir.py

  • Committer: Robert Collins
  • Date: 2007-03-29 05:00:40 UTC
  • mto: (2018.18.6 hpss-faster-copy)
  • mto: This revision was merged to the branch mainline in revision 2435.
  • Revision ID: robertc@robertcollins.net-20070329050040-mihvse1hk4mu7mxk
Fix test_format_initialize_find_open by delegating Branch formt lookup to the BzrDir, where it should have stayed from the start.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1035
1035
    def destroy_workingtree_metadata(self):
1036
1036
        self.transport.delete_tree('checkout')
1037
1037
 
 
1038
    def find_branch_format(self):
 
1039
        """Find the branch 'format' for this bzrdir.
 
1040
 
 
1041
        This might be a synthetic object for e.g. RemoteBranch and SVN.
 
1042
        """
 
1043
        from bzrlib.branch import BranchFormat
 
1044
        return BranchFormat.find_format(self)
 
1045
 
1038
1046
    def _get_mkdir_mode(self):
1039
1047
        """Figure out the mode to use when creating a bzrdir subdir."""
1040
1048
        temp_control = lockable_files.LockableFiles(self.transport, '',
1122
1130
 
1123
1131
    def open_branch(self, unsupported=False):
1124
1132
        """See BzrDir.open_branch."""
1125
 
        from bzrlib.branch import BranchFormat
1126
 
        format = BranchFormat.find_format(self)
 
1133
        format = self.find_branch_format()
1127
1134
        self._check_supported(format, unsupported)
1128
1135
        return format.open(self, _found=True)
1129
1136