~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

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

  • Committer: Jelmer Vernooij
  • Date: 2011-03-08 00:53:45 UTC
  • mto: This revision was merged to the branch mainline in revision 5705.
  • Revision ID: jelmer@samba.org-20110308005345-bkc4k0acpm61js2v
Fix imports.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
import bzrlib.branch
23
23
from bzrlib import (
24
24
    errors,
 
25
    repository,
25
26
    revision as _mod_revision,
26
27
    transport,
 
28
    workingtree,
27
29
    )
28
30
from bzrlib.tests import (
29
31
    TestSkipped,
34
36
    )
35
37
 
36
38
 
 
39
class AnonymousTestBranchFormat(bzrlib.branch.BranchFormat):
 
40
    """An anonymous branch format (does not have a format string)"""
 
41
 
 
42
    def get_format_string(self):
 
43
        raise NotImplementedError(self.get_format_string)
 
44
 
 
45
 
 
46
class IdentifiableTestBranchFormat(bzrlib.branch.BranchFormat):
 
47
    """An identifable branch format (has a format string)"""
 
48
 
 
49
    def get_format_string(self):
 
50
        return "I have an identity"
 
51
 
 
52
 
 
53
class AnonymousTestRepositoryFormat(repository.RepositoryFormat):
 
54
    """An anonymous branch format (does not have a format string)"""
 
55
 
 
56
    def get_format_string(self):
 
57
        raise NotImplementedError(self.get_format_string)
 
58
 
 
59
 
 
60
class IdentifiableTestRepositoryFormat(repository.RepositoryFormat):
 
61
    """An identifable branch format (has a format string)"""
 
62
 
 
63
    def get_format_string(self):
 
64
        return "I have an identity"
 
65
 
 
66
 
 
67
class AnonymousTestWorkingTreeFormat(workingtree.WorkingTreeFormat):
 
68
    """An anonymous branch format (does not have a format string)"""
 
69
 
 
70
    def get_format_string(self):
 
71
        raise NotImplementedError(self.get_format_string)
 
72
 
 
73
 
 
74
class IdentifiableTestWorkingTreeFormat(workingtree.WorkingTreeFormat):
 
75
    """An identifable branch format (has a format string)"""
 
76
 
 
77
    def get_format_string(self):
 
78
        return "I have an identity"
 
79
 
 
80
 
37
81
class TestBzrDir(TestCaseWithBzrDir):
38
82
 
39
83
    # Many of these tests test for disk equality rather than checking