~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/bzrdir_implementations/test_bzrdir.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2007-07-22 18:09:04 UTC
  • mfrom: (2485.8.63 bzr.connection.sharing)
  • Revision ID: pqm@pqm.ubuntu.com-20070722180904-wy7y7oyi32wbghgf
Transport connection sharing

Show diffs side-by-side

added added

removed removed

Lines of Context:
52
52
from bzrlib.tests.bzrdir_implementations import TestCaseWithBzrDir
53
53
from bzrlib.trace import mutter
54
54
from bzrlib.transport import get_transport
 
55
from bzrlib.transport.local import LocalTransport
55
56
from bzrlib.upgrade import upgrade
56
57
from bzrlib.remote import RemoteBzrDir
57
58
from bzrlib.repofmt import weaverepo
129
130
        A simple wrapper for from_bzrdir.sprout that translates NotLocalUrl into
130
131
        TestSkipped.  Returns the newly sprouted bzrdir.
131
132
        """
132
 
        try:
133
 
            target = from_bzrdir.sprout(to_url, revision_id=revision_id,
134
 
                                        force_new_repo=force_new_repo)
135
 
        except errors.NotLocalUrl:
 
133
        to_transport = get_transport(to_url)
 
134
        if not isinstance(to_transport, LocalTransport):
136
135
            raise TestSkipped('Cannot sprout to remote bzrdirs.')
 
136
        target = from_bzrdir.sprout(to_url, revision_id=revision_id,
 
137
                                    force_new_repo=force_new_repo,
 
138
                                    possible_transports=[to_transport])
137
139
        return target
138
140
 
139
141
    def test_create_null_workingtree(self):