diff options
author | xudan <xudan16@huawei.com> | 2018-05-24 04:47:41 -0400 |
---|---|---|
committer | Georg Kunz <georg.kunz@ericsson.com> | 2018-05-27 20:19:34 +0000 |
commit | 01e07c1c56d8a40cff50b077b18157decca39a5c (patch) | |
tree | da7b0e2d72dc8548388272e07db37107833bc8c9 /dovetail/run.py | |
parent | 3c0569b1e16f35d4b14a60ed25113d6d7a398272 (diff) |
Archive all test case result files
1. All detailed tempest test cases results are recorded with
file tempest-report.html rather than tempest.log now.
2. Archive all results files include functest.log, yardstick.log ...
for each test case. Otherwise, they will all be in one log file.
3. Support to set the source files and dest files need to be archived with
the test case config files rather than hardcode with the source code.
4. Give the file which used to be parse the results (PASS/FAIL) with the
test case config files rather than hardcode with the source code.
Change-Id: I30f435d91ab90cf20def47007f177fe98187484d
Signed-off-by: xudan <xudan16@huawei.com>
Diffstat (limited to 'dovetail/run.py')
-rwxr-xr-x | dovetail/run.py | 24 |
1 files changed, 1 insertions, 23 deletions
diff --git a/dovetail/run.py b/dovetail/run.py index 512565c3..19d0acb6 100755 --- a/dovetail/run.py +++ b/dovetail/run.py @@ -59,7 +59,7 @@ def run_test(testcase_list, logger): if run_testcase: testcase.run() - stop_on_fail = check_tc_result(testcase, logger) + stop_on_fail = Report.check_tc_result(testcase) try: if (not stop_on_fail or stop_on_fail['criteria'] == "FAIL") \ and dt_cfg.dovetail_config['stop']: @@ -72,28 +72,6 @@ def run_test(testcase_list, logger): return duration -def check_tc_result(testcase, logger): - result_dir = dt_cfg.dovetail_config['result_dir'] - validate_type = testcase.validate_type() - functest_result = dt_cfg.dovetail_config['functest']['result']['file_path'] - if validate_type.lower() in ['yardstick', 'bottlenecks', 'vnftest']: - result_file = os.path.join(result_dir, testcase.name() + '.out') - elif validate_type.lower() == 'functest': - result_file = os.path.join(result_dir, functest_result) - else: - logger.error("Don't support {} now.".format(validate_type)) - return - if os.path.isfile(result_file): - logger.info( - "Results have been stored with file {}.".format(result_file)) - else: - logger.error( - "Failed to store results with file {}.".format(result_file)) - result = Report.get_result(testcase) - Report.check_result(testcase, result) - return result - - def validate_input(input_dict, check_dict, logger): func_tag = input_dict['functest_tag'] yard_tag = input_dict['yardstick_tag'] |