aboutsummaryrefslogtreecommitdiffstats
path: root/ci
diff options
context:
space:
mode:
authorCédric Ollivier <cedric.ollivier@orange.com>2016-08-24 17:55:10 +0200
committerCédric Ollivier <cedric.ollivier@orange.com>2016-08-24 18:03:22 +0200
commitd6484df9b602f0888450ef1e29ccc0a5f6c94675 (patch)
tree76dc037a221f58c9fa18bbcce917ce45c60e33c6 /ci
parent2002f166154ca5a9380f9d2da2843477669af8f5 (diff)
Stop calling exec_test.sh in the middle of python scripts
Now run_tests.py calls directly OpenDaylightTesting.functest_run(). It mainly reads env vars as exec_test.sh does. Change-Id: Ibb44a7ca67e9218d34d13b8dd539e772902fe5b8 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
Diffstat (limited to 'ci')
-rwxr-xr-xci/run_tests.py14
1 files changed, 11 insertions, 3 deletions
diff --git a/ci/run_tests.py b/ci/run_tests.py
index 982567217..17481780e 100755
--- a/ci/run_tests.py
+++ b/ci/run_tests.py
@@ -13,8 +13,10 @@ import datetime
import os
import re
import sys
+
import functest.ci.generate_report as generate_report
import functest.ci.tier_builder as tb
+from functest.testcases.Controllers.ODL.OpenDaylightTesting import ODLTestCases
import functest.utils.functest_logger as ft_logger
import functest.utils.functest_utils as ft_utils
import functest.utils.openstack_clean as os_clean
@@ -100,9 +102,15 @@ def run_test(test, tier_name):
if REPORT_FLAG:
flags += " -r"
- cmd = ("%s%s" % (EXEC_SCRIPT, flags))
- logger.debug("Executing command '%s'" % cmd)
- result = ft_utils.execute_command(cmd, exit_on_error=False)
+ if test_name == 'odl':
+ result = ODLTestCases.functest_run()
+ if result and REPORT_FLAG:
+ result = ODLTestCases.push_to_db()
+ result = not result
+ else:
+ cmd = ("%s%s" % (EXEC_SCRIPT, flags))
+ logger.debug("Executing command '%s'" % cmd)
+ result = ft_utils.execute_command(cmd, exit_on_error=False)
if CLEAN_FLAG:
cleanup()