summaryrefslogtreecommitdiffstats
path: root/testcases/OpenStack
diff options
context:
space:
mode:
authorSerenaFeng <feng.xiaowei@zte.com.cn>2016-07-27 09:42:20 +0800
committerSerenaFeng <feng.xiaowei@zte.com.cn>2016-07-27 09:42:20 +0800
commite236b078f49e66b986036cca4495d5524ee332ea (patch)
tree0fd1f60f059ecf64802fbdcbdeab23717089e99c /testcases/OpenStack
parent934a16a7766a5f06b046d882eee408a725b03139 (diff)
substitue misused variable 'total_success' with 'success_rate'
JIRA: FUNCTEST-390 Change-Id: I35a2f72016573fc9e0a8403e436d5568937c5b14 Signed-off-by: SerenaFeng <feng.xiaowei@zte.com.cn>
Diffstat (limited to 'testcases/OpenStack')
-rwxr-xr-xtestcases/OpenStack/rally/run_rally-cert.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/testcases/OpenStack/rally/run_rally-cert.py b/testcases/OpenStack/rally/run_rally-cert.py
index 80c13a6c9..7d9a7cd9d 100755
--- a/testcases/OpenStack/rally/run_rally-cert.py
+++ b/testcases/OpenStack/rally/run_rally-cert.py
@@ -490,19 +490,19 @@ def main():
total_duration_str = time.strftime("%H:%M:%S", time.gmtime(total_duration))
total_duration_str2 = "{0:<10}".format(total_duration_str)
total_nb_tests_str = "{0:<13}".format(total_nb_tests)
- total_success = "{:0.2f}".format(total_success / len(SUMMARY))
- total_success_str = "{0:<10}".format(str(total_success) + '%')
+ success_rate = "{:0.2f}".format(total_success / len(SUMMARY))
+ success_rate_str = "{0:<10}".format(str(success_rate) + '%')
report += "+===================+============+===============+===========+"
report += "\n"
report += ("| TOTAL: | " + total_duration_str2 + " | " +
- total_nb_tests_str + " | " + total_success_str + "|\n")
+ total_nb_tests_str + " | " + success_rate_str + "|\n")
report += "+===================+============+===============+===========+"
report += "\n"
logger.info("\n" + report)
payload.append({'summary': {'duration': total_duration,
'nb tests': total_nb_tests,
- 'nb success': total_success}})
+ 'nb success': success_rate}})
# Generate json results for DB
# json_results = {"timestart": time_start, "duration": total_duration,
@@ -513,7 +513,7 @@ def main():
# Evaluation of the success criteria
status = "FAIL"
# for Rally we decided that the overall success rate must be above 90%
- if float(total_success) >= 90:
+ if float(success_rate) >= 90:
status = "PASS"
if args.sanity: