Mercurial > hg
changeset 37583:6939b6ac960a
py3: add b'' prefixes in tests/test-linerange.py
This makes the test pass on Python 3.
# skip-blame because just b'' prefixes
Differential Revision: https://phab.mercurial-scm.org/D3282
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Thu, 12 Apr 2018 16:52:32 +0530 |
parents | 39ced3ef586d |
children | fd0e6678ba0f |
files | tests/test-linerange.py |
diffstat | 1 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/tests/test-linerange.py Thu Apr 12 15:23:36 2018 +0530 +++ b/tests/test-linerange.py Thu Apr 12 16:52:32 2018 +0530 @@ -4,7 +4,7 @@ from mercurial import error, mdiff # for readability, line numbers are 0-origin -text1 = ''' +text1 = b''' 00 at OLD 01 at OLD 02 at OLD @@ -19,7 +19,7 @@ 11 at OLD '''[1:] # strip initial LF -text2 = ''' +text2 = b''' 00 at NEW 01 at NEW 02 at NEW, 03 at OLD @@ -47,10 +47,10 @@ def setUp(self): self.blocks = list(mdiff.allblocks(text1, text2)) assert self.blocks == [ - ([0, 3, 0, 2], '!'), - ((3, 7, 2, 6), '='), - ([7, 12, 6, 12], '!'), - ((12, 12, 12, 12), '='), + ([0, 3, 0, 2], b'!'), + ((3, 7, 2, 6), b'='), + ([7, 12, 6, 12], b'!'), + ((12, 12, 12, 12), b'='), ], self.blocks def testWithinEqual(self):