/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/git/tests/test_branch.py

  • Committer: Jelmer Vernooij
  • Date: 2018-11-16 23:19:12 UTC
  • mfrom: (7180 work)
  • mto: This revision was merged to the branch mainline in revision 7294.
  • Revision ID: jelmer@jelmer.uk-20181116231912-e043vpq22bdkxa6q
Merge trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
115
115
        revb = r.do_commit(b"b", committer=b"Somebody <foo@example.com>")
116
116
 
117
117
        thebranch = Branch.open('.')
118
 
        self.assertEqual((2, default_mapping.revision_id_foreign_to_bzr(revb)), thebranch.last_revision_info())
 
118
        self.assertEqual((2, default_mapping.revision_id_foreign_to_bzr(
 
119
            revb)), thebranch.last_revision_info())
119
120
 
120
121
    def test_tag_annotated(self):
121
122
        reva = self.simple_commit_a()
131
132
        r[b'refs/tags/foo'] = o.id
132
133
        thebranch = Branch.open('.')
133
134
        self.assertEqual({"foo": default_mapping.revision_id_foreign_to_bzr(reva)},
134
 
                          thebranch.tags.get_tag_dict())
 
135
                         thebranch.tags.get_tag_dict())
135
136
 
136
137
    def test_tag(self):
137
138
        reva = self.simple_commit_a()
139
140
        r.refs[b"refs/tags/foo"] = reva
140
141
        thebranch = Branch.open('.')
141
142
        self.assertEqual({"foo": default_mapping.revision_id_foreign_to_bzr(reva)},
142
 
                          thebranch.tags.get_tag_dict())
143
 
 
 
143
                         thebranch.tags.get_tag_dict())
144
144
 
145
145
 
146
146
class TestWithGitBranch(tests.TestCaseWithTransport):
156
156
 
157
157
    def test_get_stacked_on_url(self):
158
158
        self.assertRaises(UnstackableBranchFormat,
159
 
            self.git_branch.get_stacked_on_url)
 
159
                          self.git_branch.get_stacked_on_url)
160
160
 
161
161
    def test_get_physical_lock_status(self):
162
162
        self.assertFalse(self.git_branch.get_physical_lock_status())
169
169
        self.format = branch.LocalGitBranchFormat()
170
170
 
171
171
    def test_get_format_description(self):
172
 
        self.assertEqual("Local Git Branch", self.format.get_format_description())
 
172
        self.assertEqual("Local Git Branch",
 
173
                         self.format.get_format_description())
173
174
 
174
175
    def test_get_network_name(self):
175
176
        self.assertEqual(b"git", self.format.network_name())