# HG changeset patch
# User Augie Fackler <r...@durin42.com>
# Date 1505518982 14400
#      Fri Sep 15 19:43:02 2017 -0400
# Node ID 34469e4e2187381259d78ec0a35c2dd5b0e9e85a
# Parent  d08554602cdbd245ddd213af325473da037a240f
posix: fix HFS+ normcase doctest to produce valid bytes literals in Python 3

We were previously getting lucky on Python 2.

diff --git a/mercurial/posix.py b/mercurial/posix.py
--- a/mercurial/posix.py
+++ b/mercurial/posix.py
@@ -344,11 +344,11 @@ if pycompat.sysplatform == 'darwin':
 
         >>> normcase(b'UPPER')
         'upper'
-        >>> normcase(b'Caf\xc3\xa9')
+        >>> normcase(b'Caf\\xc3\\xa9')
         'cafe\\xcc\\x81'
-        >>> normcase(b'\xc3\x89')
+        >>> normcase(b'\\xc3\\x89')
         'e\\xcc\\x81'
-        >>> normcase(b'\xb8\xca\xc3\xca\xbe\xc8.JPG') # issue3918
+        >>> normcase(b'\\xb8\\xca\\xc3\\xca\\xbe\\xc8.JPG') # issue3918
         '%b8%ca%c3\\xca\\xbe%c8.jpg'
         '''
 
_______________________________________________
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel

Reply via email to