From ab98e4d5d2009499597974ff5bbe6f57a8d4ba13 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Sun, 4 Aug 2013 03:48:18 +0000 Subject: [PATCH] improve parse_test_results --- tools/parse_test_results.py | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/tools/parse_test_results.py b/tools/parse_test_results.py index bceaaed0d..378b9af37 100755 --- a/tools/parse_test_results.py +++ b/tools/parse_test_results.py @@ -46,7 +46,7 @@ def style_output(o): l = l.replace('<', '<') l = l.replace('>', '>') if 'TEST_CHECK' in l or 'TEST_EQUAL_ERROR' in l or l.startswith('EXIT STATUS: ') or \ - l.endswith(' second time limit exceeded') or l.startswith('signal: SIG'): + ' second time limit exceeded' in l or l.startswith('signal: SIG'): ret += '%s\n' % l elif '**passed**' in l: ret += '%s\n' % l @@ -213,22 +213,25 @@ for branch_name in revs: table { border: 0; border-collapse: collapse; } h1 { font-size: 15pt; } th { font-size: 8pt; } - td { border: 0; border-spacing: 0px; padding: 1px 1px 0px 0px; } + td { border: 0; border-spacing: 0px; padding: 1px 0px 0px 1px; } .left-head { white-space: nowrap; }

%s - %s

''' % (project_name, project_name, branch_name) print >>html, '' - for r in range(latest_rev, latest_rev - 20, -1): + num_printed_revs = 0; + for r in range(latest_rev, latest_rev - 40, -1): sys.stdout.write('.') sys.stdout.flush() - print >>html, '' % r - rev_dir = '%s-%d' % (branch_name, r) (platforms, tests) = parse_tests(rev_dir) + if len(tests) + len(platforms) == 0: continue + + print >>html, '' % r + for f in tests: print >>html, '' % (len(tests[f]), len(tests[f])*9 - 5, f) print >>html, '' @@ -250,6 +253,8 @@ for branch_name in revs: print >>html, '' idx += 1 + num_printed_revs += 1 + if num_printed_revs >= 20: break print >>html, '
revision %d
revision %d%s
' html.close()