~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/test_transport.py

[merge] up-to-date against bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
 
21
21
from bzrlib.errors import (NoSuchFile, FileExists, TransportNotPossible,
22
22
                           ConnectionError)
23
 
from bzrlib.selftest import TestCase, TestCaseInTempDir
24
 
from bzrlib.selftest.HTTPTestUtil import TestCaseWithWebserver
 
23
from bzrlib.tests import TestCase, TestCaseInTempDir
 
24
from bzrlib.tests.HTTPTestUtil import TestCaseWithWebserver
25
25
from bzrlib.transport import memory, urlescape
26
26
 
27
27
 
469
469
        if not hasattr(self, "get_bogus_transport"):
470
470
            return
471
471
        t = self.get_bogus_transport()
472
 
        self.assertRaises(ConnectionError, t.get, '.bzr/branch')
 
472
        try:
 
473
            t.get('.bzr/branch')
 
474
        except (ConnectionError, NoSuchFile), e:
 
475
            pass
 
476
        except (Exception), e:
 
477
            self.failIf(True, 'Wrong exception thrown: %s' % e)
 
478
        else:
 
479
            self.failIf(True, 'Did not get the expected exception.')
473
480
 
474
481
        
475
482
class LocalTransportTest(TestCaseInTempDir, TestTransportMixIn):