Skip to content
Snippets Groups Projects
Commit bd0f122f authored by Manuel Jacob's avatar Manuel Jacob
Browse files

run-tests: fix escapes with conditions

Before this fix, escapes with conditions in tests failed like this on Python 3:

   $ $PYTHON -c 'from mercurial.utils.procutil import stdout; stdout.write(b"\xff")'
-  \xff (no-eol) (esc) (true !)
+  \xff (no-eol) (esc)

The unicode_escape encoding decodes br'\xff' to u'\xff'. To convert the first
256 code points to bytes with the same ordinal, the latin-1 encoding must be
used.

Escapes without conditions already worked before on Python 3, but not through
`el == l` a few lines below the changed line in run-tests.py. I didn’t
investigate further.
parent 5c0d5b48
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment