summaryrefslogtreecommitdiffstats
path: root/testcases/Controllers/ODL
diff options
context:
space:
mode:
authorjose.lausuch <jose.lausuch@ericsson.com>2016-07-20 19:34:51 +0200
committerjose.lausuch <jose.lausuch@ericsson.com>2016-07-20 21:17:41 +0200
commitb885491e3c2d5a1bd947631afd96ed8006ef8771 (patch)
tree0a58a99f2b9474758ed8c6c87822908715e71718 /testcases/Controllers/ODL
parentc82af629f53002f84ad22fc339201671896afb37 (diff)
Bugfix: ODL report to DB fails
JIRA: FUNCTEST-370 Change-Id: I48c8927f3490b86fcf1c95656324429b70201653 Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
Diffstat (limited to 'testcases/Controllers/ODL')
-rwxr-xr-xtestcases/Controllers/ODL/odlreport2db.py16
1 files changed, 10 insertions, 6 deletions
diff --git a/testcases/Controllers/ODL/odlreport2db.py b/testcases/Controllers/ODL/odlreport2db.py
index 0c9f341c9..368d26611 100755
--- a/testcases/Controllers/ODL/odlreport2db.py
+++ b/testcases/Controllers/ODL/odlreport2db.py
@@ -66,12 +66,16 @@ def parse_test(tests, details):
def parse_suites(suites):
data = {}
details = []
- try:
- for suite in suites:
- data['details'] = parse_test(suite['test'], details)
- except TypeError:
- # suites is not iterable
- data['details'] = parse_test(suites['test'], details)
+ for suite in suites:
+ a = suite['suite']
+ if type(a) == list:
+ for b in a:
+ data['details'] = parse_test(b['test'], details)
+ else:
+ data['details'] = parse_test(a['test'], details)
+
+ # data['details'] = parse_test(suite['test'], details)
+ # suites is not iterable
return data