aboutsummaryrefslogtreecommitdiffstats
path: root/xtesting/ci
diff options
context:
space:
mode:
Diffstat (limited to 'xtesting/ci')
-rw-r--r--xtesting/ci/run_tests.py14
-rw-r--r--xtesting/ci/tier_handler.py4
2 files changed, 9 insertions, 9 deletions
diff --git a/xtesting/ci/run_tests.py b/xtesting/ci/run_tests.py
index c8983b46..61482d98 100644
--- a/xtesting/ci/run_tests.py
+++ b/xtesting/ci/run_tests.py
@@ -49,11 +49,6 @@ class BlockingTestFailed(Exception):
pass
-class TestNotEnabled(Exception):
- """Exception when the test is not enabled"""
- pass
-
-
class RunTestsParser(object):
"""Parser to run tests"""
# pylint: disable=too-few-public-methods
@@ -144,8 +139,13 @@ class Runner(object):
def run_test(self, test):
"""Run one test case"""
if not test.is_enabled():
- raise TestNotEnabled(
- "The test case {} is not enabled".format(test.get_name()))
+ msg = prettytable.PrettyTable(
+ header_style='upper', padding_width=5,
+ field_names=['test case', 'project', 'duration',
+ 'result'])
+ msg.add_row([test.get_name(), test.get_project(), "00:00", "SKIP"])
+ LOGGER.info("Test result:\n\n%s\n", msg)
+ return testcase.TestCase.EX_TESTCASE_SKIPPED
result = testcase.TestCase.EX_RUN_ERROR
run_dict = self.get_run_dict(test.get_name())
if run_dict:
diff --git a/xtesting/ci/tier_handler.py b/xtesting/ci/tier_handler.py
index 7a77e4cf..11a0858e 100644
--- a/xtesting/ci/tier_handler.py
+++ b/xtesting/ci/tier_handler.py
@@ -65,13 +65,13 @@ class Tier(object):
def get_test(self, test_name):
if self.is_test(test_name):
- for test in self.tests_array:
+ for test in self.tests_array + self.skipped_tests_array:
if test.get_name() == test_name:
return test
return None
def is_test(self, test_name):
- for test in self.tests_array:
+ for test in self.tests_array + self.skipped_tests_array:
if test.get_name() == test_name:
return True
return False