~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/per_interrepository/__init__.py

  • Committer: Jelmer Vernooij
  • Date: 2011-02-24 16:09:13 UTC
  • mto: (5582.10.69 weave-fmt-plugin)
  • mto: This revision was merged to the branch mainline in revision 5688.
  • Revision ID: jelmer@samba.org-20110224160913-em1vv5nfiu185s4k
Move interrepo extra combinations function to module level.

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
    )
34
34
 
35
35
from bzrlib.repository import (
36
 
    format_registry,
 
36
    _get_repository_modules,
37
37
    InterDifferingSerializer,
38
38
    InterRepository,
39
39
    )
101
101
    # Gather extra scenarios from the repository implementations,
102
102
    # as InterRepositories can be used by Repository implementations
103
103
    # they aren't aware of.
104
 
    for repo_format in format_registry._get_all():
 
104
    for module in _get_repository_modules():
 
105
        try:
 
106
            get_extra_interrepo_test_combinations = getattr(module,
 
107
                "get_extra_interrepo_test_combinations")
 
108
        except AttributeError:
 
109
            continue
105
110
        for (interrepo_cls, from_format, to_format) in (
106
 
            repo_format._get_extra_interrepo_test_combinations()):
 
111
            get_extra_interrepo_test_combinations()):
107
112
            add_combo(interrepo_cls, from_format, to_format)
108
113
    add_combo(InterRepository,
109
114
              knitrepo.RepositoryFormatKnit1(),