[benchmark] LogParser: Accept -?! in bench. names

Extend parser to support benchmark names that include `-?!` in names, to fully support the new Naming Convention from PR #20334.
This commit is contained in:
Pavol Vaskovic
2019-02-19 23:31:58 +01:00
parent 84e7d4dfb8
commit 691007b029
2 changed files with 11 additions and 5 deletions

View File

@@ -363,9 +363,9 @@ class LogParser(object):
# Parse lines like this
# #,TEST,SAMPLES,MIN(μs),MAX(μs),MEAN(μs),SD(μs),MEDIAN(μs)
results_re = re.compile(
r'( *\d+[, \t]+[\w.]+[, \t]+' + # #,TEST
r'[, \t]+'.join([r'\d+'] * 2) + # at least 2...
r'(?:[, \t]+\d*)*)') # ...or more numeric columns
r'( *\d+[, \t]+[\w.\-\?!]+[, \t]+' + # #,TEST
r'[, \t]+'.join([r'\d+'] * 2) + # at least 2...
r'(?:[, \t]+\d*)*)') # ...or more numeric columns
def _append_result(self, result):
columns = result.split(',') if ',' in result else result.split()