Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimofey <t.danshin@corp.mail.ru>2017-02-28 13:28:57 +0300
committerTimofey <t.danshin@corp.mail.ru>2017-02-28 13:28:57 +0300
commit2edc2fc85db01324945a9229595b0a5436505db1 (patch)
treecee73ff8c9661c0a158fdc6a79f992e5ea0ba4ce /tools/python
parentfce669d15b40e5ad84ccab924769dc26c21d284a (diff)
Added more characters for replacement in log to xml converter.
Diffstat (limited to 'tools/python')
-rwxr-xr-xtools/python/testlog_to_xml_converter.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/python/testlog_to_xml_converter.py b/tools/python/testlog_to_xml_converter.py
index 62f8e3a2ba..4ae31475c8 100755
--- a/tools/python/testlog_to_xml_converter.py
+++ b/tools/python/testlog_to_xml_converter.py
@@ -15,6 +15,8 @@ import xml.etree.ElementTree as ElementTree
from optparse import OptionParser
import re
+REPLACE_CHARS_RE = re.compile("[\x00-\x1f]")
+
class PrefixesInLog:
OK = "OK"
@@ -202,7 +204,7 @@ class Parser:
if line == "All tests passed." or re.match("\d{1,} tests failed", line, re.IGNORECASE):
self.var_should_pass = True
return False
- line = line.replace("\0", "\\0")
+ line = REPLACE_CHARS_RE.sub("_", line)
self.test_info.append_comment(line)
return False