aboutsummaryrefslogtreecommitdiffstats
path: root/functest/ci/run_tests.py
diff options
context:
space:
mode:
authorjose.lausuch <jose.lausuch@ericsson.com>2017-05-16 11:28:14 +0200
committerJose Lausuch <jose.lausuch@ericsson.com>2017-05-16 14:29:48 +0000
commitd180eabc5a2c2453d04bb4a080874c329605c026 (patch)
treef41fb4c9cfcbe62c03868f25bc6c673a66651ecd /functest/ci/run_tests.py
parent8cfa8d15a572cbae8bd46dae2a19f9b764684a12 (diff)
Add enabled flag in testcases.yaml
This will allow enable/disable test cases directly using true/false. Change-Id: Iaa7d051ebb8dd9e5a6f835a823f58f1e17a87b8d Signed-off-by: jose.lausuch <jose.lausuch@ericsson.com>
Diffstat (limited to 'functest/ci/run_tests.py')
-rwxr-xr-xfunctest/ci/run_tests.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/functest/ci/run_tests.py b/functest/ci/run_tests.py
index 493d5f9c..76760096 100755
--- a/functest/ci/run_tests.py
+++ b/functest/ci/run_tests.py
@@ -40,6 +40,10 @@ class BlockingTestFailed(Exception):
pass
+class TestNotEnabled(Exception):
+ pass
+
+
class RunTestsParser(object):
def __init__(self):
@@ -114,6 +118,9 @@ def get_run_dict(testname):
def run_test(test, tier_name, testcases=None):
+ if not test.is_enabled():
+ raise TestNotEnabled("The test case {} is not enabled"
+ .format(test.get_name()))
test_name = test.get_name()
logger.info("\n") # blank line
print_separator("=")