aboutsummaryrefslogtreecommitdiffstats
path: root/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
diff options
context:
space:
mode:
authoropensource-tnbt <sridhar.rao@spirent.com>2020-12-01 16:46:31 +0530
committeropensource-tnbt <sridhar.rao@spirent.com>2020-12-01 16:47:38 +0530
commitd7a033d9e40eedee5e0413cb2f0898fc82364f58 (patch)
treee69740c762fcb26f6519a72b62ed2f640e99e8d8 /tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
parent0bbc7e2674bd06921e9fe4a0b3318724327d3ff2 (diff)
Tools: Improve Stability.
This patch has minor updates to improve stability. Signed-off-by: Sridhar K. N. Rao <sridhar.rao@spirent.com> Change-Id: I0ded30c64389d75f15d2a8758a40dfb5cf3ff674
Diffstat (limited to 'tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py')
-rw-r--r--tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py b/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
index 2f0cb0b4..8089ef42 100644
--- a/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
+++ b/tools/pkt_gen/testcenter/testcenter-rfc2544-rest.py
@@ -691,6 +691,11 @@ def main():
lab_server_resultsdb = stc.get(
"system1.project.TestResultSetting", "CurrentResultFileName")
+ if not lab_server_resultsdb or 'Results' not in lab_server_resultsdb:
+ _LOGGER.info("Failed to find results.")
+ stc.end_session()
+ return
+
if args.verbose:
_LOGGER.debug("The lab server results database is %s",
lab_server_resultsdb)
@@ -811,6 +816,7 @@ def main():
args.results_dir, args.csv_results_file_prefix, resultsdict)
except RuntimeError as e:
+ stc.end_session()
_LOGGER.error(e)
if args.verbose: