~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/per_transport.py

  • Committer: Vincent Ladeuil
  • Date: 2010-10-15 11:25:40 UTC
  • mfrom: (5436.2.9 hooks-refactoring)
  • mto: This revision was merged to the branch mainline in revision 5500.
  • Revision ID: v.ladeuil+lp@free.fr-20101015112540-vhgyone6ou1g0foo
Merge lp:~spiv/bzr/hooks-refactoring with tweaks

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
from StringIO import StringIO as pyStringIO
27
27
import stat
28
28
import sys
29
 
import unittest
30
29
 
31
30
from bzrlib import (
32
31
    errors,
33
32
    osutils,
 
33
    pyutils,
34
34
    tests,
35
35
    urlutils,
36
36
    )
37
37
from bzrlib.errors import (ConnectionError,
38
 
                           DirectoryNotEmpty,
39
38
                           FileExists,
40
39
                           InvalidURL,
41
 
                           LockError,
42
40
                           NoSuchFile,
43
 
                           NotLocalUrl,
44
41
                           PathError,
45
42
                           TransportNotPossible,
46
43
                           )
47
44
from bzrlib.osutils import getcwd
48
45
from bzrlib.smart import medium
49
46
from bzrlib.tests import (
50
 
    TestCaseInTempDir,
51
47
    TestSkipped,
52
48
    TestNotApplicable,
53
49
    multiply_tests,
78
74
    for module in _get_transport_modules():
79
75
        try:
80
76
            permutations = get_transport_test_permutations(
81
 
                reduce(getattr, (module).split('.')[1:], __import__(module)))
 
77
                pyutils.get_named_object(module))
82
78
            for (klass, server_factory) in permutations:
83
79
                scenario = ('%s,%s' % (klass.__name__, server_factory.__name__),
84
80
                    {"transport_class":klass,