~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/remote.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:
85
85
        real_workingtree = self._real_bzrdir.create_workingtree(revision_id=revision_id)
86
86
        return RemoteWorkingTree(self, real_workingtree)
87
87
 
 
88
    def find_branch_format(self):
 
89
        """Find the branch 'format' for this bzrdir.
 
90
 
 
91
        This might be a synthetic object for e.g. RemoteBranch and SVN.
 
92
        """
 
93
        b = self.open_branch()
 
94
        return b._format
 
95
 
88
96
    def open_branch(self, _unsupported=False):
89
97
        assert _unsupported == False, 'unsupported flag support not implemented yet.'
90
98
        path = self._path_for_remote_call(self._client)
614
622
 
615
623
class RemoteBranchFormat(branch.BranchFormat):
616
624
 
 
625
    def __eq__(self, other):
 
626
        return (isinstance(other, RemoteBranchFormat) and 
 
627
            self.__dict__ == other.__dict__)
 
628
 
617
629
    def get_format_description(self):
618
630
        return 'Remote BZR Branch'
619
631