[PATCH 2 of 2] run-tests: assign value to ESCAPEMAP - dict.update do not return self
Mads Kiilerich
mads at kiilerich.com
Sun May 25 06:48:37 CDT 2014
# HG changeset patch
# User Mads Kiilerich <madski at unity3d.com>
# Date 1401018462 -7200
# Sun May 25 13:47:42 2014 +0200
# Node ID 665481b33700b726fb48fd7bc930239499f2ac65
# Parent c5e55adeb37b9e1bcaec2e9fc3745f47d568e3d1
run-tests: assign value to ESCAPEMAP - dict.update do not return self
a36cc85a5b7b did more than what the description said and introduced a bug.
diff --git a/tests/run-tests.py b/tests/run-tests.py
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -675,8 +675,8 @@ class TTest(Test):
NEEDESCAPE = re.compile(r'[\x00-\x08\x0b-\x1f\x7f-\xff]').search
ESCAPESUB = re.compile(r'[\x00-\x08\x0b-\x1f\\\x7f-\xff]').sub
- ESCAPEMAP = dict((chr(i), r'\x%02x' % i) for i in range(256)).update(
- {'\\': '\\\\', '\r': r'\r'})
+ ESCAPEMAP = dict((chr(i), r'\x%02x' % i) for i in range(256))
+ ESCAPEMAP.update({'\\': '\\\\', '\r': r'\r'})
@property
def refpath(self):
More information about the Mercurial-devel
mailing list