aboutsummaryrefslogtreecommitdiffstats
path: root/testcases/features/doctor.py
diff options
context:
space:
mode:
authorMorgan Richomme <morgan.richomme@orange.com>2016-03-18 13:10:23 +0000
committerGerrit Code Review <gerrit@172.30.200.206>2016-03-18 13:10:23 +0000
commit26fa022ae631922f22978f79b2912fd56f133ab2 (patch)
treefa428f2560ed5f9ccb266f8411a2dbb4295fb0e0 /testcases/features/doctor.py
parentfd95510eb2caa63ec1613b271fb620f9c66e2278 (diff)
parent7c9aef8db83e025034e3427c1330a00420fae50a (diff)
Merge "Add criteria and version when pushing the results into test DB"
Diffstat (limited to 'testcases/features/doctor.py')
-rw-r--r--testcases/features/doctor.py17
1 files changed, 12 insertions, 5 deletions
diff --git a/testcases/features/doctor.py b/testcases/features/doctor.py
index 52ffaa90..a225d5a5 100644
--- a/testcases/features/doctor.py
+++ b/testcases/features/doctor.py
@@ -15,7 +15,6 @@
#
import logging
-import os
import sys
import time
import yaml
@@ -63,19 +62,27 @@ def main():
}
pod_name = functest_utils.get_pod_name(logger)
scenario = functest_utils.get_scenario(logger)
+ version = scenario
build_tag = functest_utils.get_build_tag(logger)
+
+ status = "failed"
+ if details['status'] == "OK":
+ status = "passed"
+
logger.info("Pushing result: TEST_DB_URL=%(db)s pod_name=%(pod)s "
- "scenario=%(s)s details=%(d)s" % {
+ "version=%(v)s scenario=%(s)s criteria=%(c)s details=%(d)s" % {
'db': TEST_DB_URL,
'pod': pod_name,
+ 'v': version,
's': scenario,
+ 'c': status,
'b': build_tag,
'd': details,
})
functest_utils.push_results_to_db(TEST_DB_URL,
- 'doctor','doctor-notification',
- logger, pod_name, scenario,
- build_tag, details)
+ 'doctor', 'doctor-notification',
+ logger, pod_name, version, scenario,
+ status, build_tag, details)
if __name__ == '__main__':