/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/tests/test_patches.py

  • Committer: Jelmer Vernooij
  • Date: 2018-11-17 00:47:52 UTC
  • mfrom: (7182 work)
  • mto: This revision was merged to the branch mainline in revision 7305.
  • Revision ID: jelmer@jelmer.uk-20181117004752-6ywampe5pfywlby4
Merge trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
184
184
                              b'Binary files bar\t.* and qux\t.* differ\n')
185
185
 
186
186
    def test_parse_binary_after_normal(self):
187
 
        patches = list(parse_patches(self.data_lines("binary-after-normal.patch")))
 
187
        patches = list(parse_patches(
 
188
            self.data_lines("binary-after-normal.patch")))
188
189
        self.assertIs(BinaryPatch, patches[1].__class__)
189
190
        self.assertIs(Patch, patches[0].__class__)
190
191
        self.assertContainsRe(patches[1].oldname, b'^bar\t')
200
201
    def testInit(self):
201
202
        """Handle patches missing half the position, range tuple"""
202
203
        patchtext = \
203
 
b"""--- orig/__vavg__.cl
 
204
            b"""--- orig/__vavg__.cl
204
205
+++ mod/__vavg__.cl
205
206
@@ -1 +1,2 @@
206
207
 __qbpsbezng__ = "erfgehpgherqgrkg ra"
283
284
    def testParsePatches(self):
284
285
        """Make sure file names can be extracted from tricky unified diffs"""
285
286
        patchtext = \
286
 
b"""--- orig-7
 
287
            b"""--- orig-7
287
288
+++ mod-7
288
289
@@ -1,10 +1,10 @@
289
290
 -- a