From 13e644d0ba893ddc5e2944c2e827fde7cd58ae72 Mon Sep 17 00:00:00 2001 From: xudan Date: Tue, 11 Dec 2018 01:41:15 -0500 Subject: Enable ShellRunner 1. fix the bug 'ShellRunner' object has no attribute 'archive_logs' 2. remove the testarea_supported because it's not very necessary for the test cases themselves and can make it a little more simple to add a test case with new test area JIRA: DOVETAIL-750 Change-Id: I71ee74615200376adca2a0db040753e5fce329bc Signed-off-by: xudan --- dovetail/report.py | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) (limited to 'dovetail/report.py') diff --git a/dovetail/report.py b/dovetail/report.py index 26cd6c52..f11bb242 100644 --- a/dovetail/report.py +++ b/dovetail/report.py @@ -121,22 +121,15 @@ class Report(object): sub_report = collections.OrderedDict() testcase_num = {} testcase_passnum = {} - for area in dt_cfg.dovetail_config['testarea_supported']: - sub_report[area] = '' - testcase_num[area] = 0 - testcase_passnum[area] = 0 testarea_scope = [] for testcase in report_data['testcases_list']: - supported_areas = dt_cfg.dovetail_config['testarea_supported'] - pattern = re.compile('|'.join(supported_areas)) - area = pattern.findall(testcase['name']) - if not supported_areas or not area: - self.logger.error('Test case {} not in supported testarea.' - .format(testcase['name'])) - return None - area = area[0] - testarea_scope.append(area) + area = testcase['name'].split('.')[1] + if area not in testarea_scope: + testarea_scope.append(area) + sub_report[area] = '' + testcase_num[area] = 0 + testcase_passnum[area] = 0 sub_report[area] += '-%-25s %s\n' %\ (testcase['name'], testcase['result']) if 'sub_testcase' in testcase: -- cgit 1.2.3-korg