From a59f1ec0c6877937d975334b9b5b40fc80ed571a Mon Sep 17 00:00:00 2001 From: "shadi@chromium.org" Date: Thu, 19 Dec 2013 19:20:17 +0000 Subject: Fix layout test analyzer post changes in parsing expectations. In specific, LTA broke post https://codereview.chromium.org/20830003 BUG=None TEST=python layouttest_analyzer_runner.py --issue-detail-mode Review URL: https://codereview.chromium.org/113973006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@241907 0039d316-1c4b-4281-b951-d872f2087c98 --- media/tools/layout_tests/layouttest_analyzer.py | 4 ++-- media/tools/layout_tests/test_expectations.py | 22 +++------------------- 2 files changed, 5 insertions(+), 21 deletions(-) (limited to 'media/tools') diff --git a/media/tools/layout_tests/layouttest_analyzer.py b/media/tools/layout_tests/layouttest_analyzer.py index 7459a97..5668767 100755 --- a/media/tools/layout_tests/layouttest_analyzer.py +++ b/media/tools/layout_tests/layouttest_analyzer.py @@ -416,8 +416,8 @@ def UpdateDashboard(dashboard_file_location, test_group_name, data_map, 'skip_tests_count': len(data_map['skip'][0]), 'nonskip_tests_path': escaped_tg_name + '_nonskip.html', 'nonskip_tests_count': len(data_map['nonskip'][0]), - 'fail_rate': 100 - int(data_map['passingrate'][0]), - 'passing_rate': int(data_map['passingrate'][0]), + 'fail_rate': 100 - float(data_map['passingrate'][0]), + 'passing_rate': float(data_map['passingrate'][0]), 'rev_url': DEFAULT_REVISION_VIEW_URL % rev, 'rev': rev, 'rev_date': rev_date, diff --git a/media/tools/layout_tests/test_expectations.py b/media/tools/layout_tests/test_expectations.py index 58b21de..b68bc09 100644 --- a/media/tools/layout_tests/test_expectations.py +++ b/media/tools/layout_tests/test_expectations.py @@ -97,27 +97,11 @@ class TestExpectations(object): return None, None test_expectation_info['Comments'] = parsed.comment or '' - - # Split the modifiers dictionary into the format we want. - remaining_modifiers = list(parsed.modifiers) - test_expectation_info['Bugs'] = [] - for m in parsed.modifiers: - if (m.startswith(WEBKIT_BUG_PREFIX) or - m.startswith(CHROMIUM_BUG_PREFIX) or - m.startswith(V8_BUG_PREFIX) or - m.startswith(NAMED_BUG_PREFIX)): - test_expectation_info['Bugs'].append(m) - remaining_modifiers.remove(m) - elif m in KNOWN_TE_KEYWORDS: - test_expectation_info[m] = True - remaining_modifiers.remove(m) - - # The modifiers left over should all be platform names. - test_expectation_info['Platforms'] = list(remaining_modifiers) - + test_expectation_info['Bugs'] = parsed.bugs or []; + test_expectation_info['Platforms'] = parsed.specifiers or [] # Shovel the expectations and modifiers in as ": True" entries. Ugly, # but required by the rest of the pipeline for parsing. - for m in parsed.expectations + remaining_modifiers: + for m in parsed.expectations: test_expectation_info[m] = True return parsed.name, test_expectation_info -- cgit v1.1