# HG changeset patch # User Yuya Nishihara # Date 2010-10-02 13:57:25 # Node ID d4e21a9de8bcdb86a17917deb680d24fcd52c39b # Parent 97fd67f35c008f0e0e0d459b3f35cdcd199a2048 tests: accept \-escaped test output It changes tsttest to accept expected outputs in python-style \-escapes. It aims to avoid trouble with outputs for non-ascii, color and progress tests. diff --git a/tests/run-tests.py b/tests/run-tests.py --- a/tests/run-tests.py +++ b/tests/run-tests.py @@ -546,6 +546,8 @@ def tsttest(test, options, replacements) if el == l: # perfect match (fast) postout.append(" " + l) + elif el and el.decode('string-escape') == l: + postout.append(" " + el) # \-escape match elif (el and (el.endswith(" (re)\n") and rematch(el[:-6] + '\n', l) or el.endswith(" (glob)\n") and globmatch(el[:-8] + '\n', l))):