~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/tests/per_branch/test_create_clone.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2009-08-14 15:22:39 UTC
  • mfrom: (4523.4.21 1.18-lock-warnings)
  • Revision ID: pqm@pqm.ubuntu.com-20090814152239-m0ybwy7vfs32exeh
(jam) Update the test suite to cause failures when we take out
        multiple locks on the same file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
class TestCreateClone(TestCaseWithBranch):
27
27
 
28
28
    def test_create_clone_on_transport_missing_parent_dir(self):
 
29
        self.thisFailsStrictLockCheck()
29
30
        tree = self.make_branch_and_tree('source')
30
31
        tree.commit('a commit')
31
32
        source = tree.branch
35
36
        self.assertFalse(self.get_transport('.').has('subdir'))
36
37
 
37
38
    def test_create_clone_on_transport_missing_parent_dir_create(self):
 
39
        self.thisFailsStrictLockCheck()
38
40
        tree = self.make_branch_and_tree('source')
39
41
        tree.commit('a commit')
40
42
        source = tree.branch
46
48
            result.bzrdir.root_transport.base)
47
49
 
48
50
    def test_create_clone_on_transport_use_existing_dir_false(self):
 
51
        self.thisFailsStrictLockCheck()
49
52
        tree = self.make_branch_and_tree('source')
50
53
        tree.commit('a commit')
51
54
        source = tree.branch
56
59
        self.assertFalse(target_transport.has(".bzr"))
57
60
 
58
61
    def test_create_clone_on_transport_use_existing_dir_true(self):
 
62
        self.thisFailsStrictLockCheck()
59
63
        tree = self.make_branch_and_tree('source')
60
64
        tree.commit('a commit')
61
65
        source = tree.branch
66
70
        self.assertEqual(source.last_revision(), result.last_revision())
67
71
 
68
72
    def test_create_clone_on_transport_no_revision_id(self):
 
73
        self.thisFailsStrictLockCheck()
69
74
        tree = self.make_branch_and_tree('source')
70
75
        tree.commit('a commit')
71
76
        source = tree.branch
74
79
        self.assertEqual(source.last_revision(), result.last_revision())
75
80
 
76
81
    def test_create_clone_on_transport_revision_id(self):
 
82
        self.thisFailsStrictLockCheck()
77
83
        tree = self.make_branch_and_tree('source')
78
84
        old_revid = tree.commit('a commit')
79
85
        source_tip = tree.commit('a second commit')
87
93
        self.assertFalse(result.repository.has_revision(source_tip))
88
94
 
89
95
    def test_create_clone_on_transport_stacked(self):
 
96
        self.thisFailsStrictLockCheck()
90
97
        tree = self.make_branch_and_tree('source')
91
98
        tree.commit('a commit')
92
99
        trunk = tree.branch.create_clone_on_transport(
100
107
        self.assertEqual(trunk.base, result.get_stacked_on_url())
101
108
 
102
109
    def test_create_clone_of_multiple_roots(self):
 
110
        self.thisFailsStrictLockCheck()
103
111
        try:
104
112
            builder = self.make_branch_builder('local')
105
113
        except (errors.TransportNotPossible, errors.UninitializableFormat):
121
129
        self.hook_calls.append(pre_change_params)
122
130
 
123
131
    def test_create_clone_on_transport_stacked_hooks_get_stacked_branch(self):
 
132
        self.thisFailsStrictLockCheck()
124
133
        tree = self.make_branch_and_tree('source')
125
134
        tree.commit('a commit')
126
135
        trunk = tree.branch.create_clone_on_transport(