aboutsummaryrefslogtreecommitdiffstats
path: root/xtesting
diff options
context:
space:
mode:
Diffstat (limited to 'xtesting')
-rw-r--r--xtesting/ci/run_tests.py5
-rw-r--r--xtesting/ci/testcases.yaml1
-rw-r--r--xtesting/ci/tier_builder.py2
-rw-r--r--xtesting/ci/tier_handler.py11
-rw-r--r--xtesting/tests/unit/ci/test_tier_builder.py4
-rw-r--r--xtesting/tests/unit/ci/test_tier_handler.py9
6 files changed, 8 insertions, 24 deletions
diff --git a/xtesting/ci/run_tests.py b/xtesting/ci/run_tests.py
index f96bd885..ea606bd4 100644
--- a/xtesting/ci/run_tests.py
+++ b/xtesting/ci/run_tests.py
@@ -219,12 +219,11 @@ class Runner():
tiers_to_run = []
msg = prettytable.PrettyTable(
header_style='upper', padding_width=5,
- field_names=['tiers', 'order', 'description',
- 'testcases'])
+ field_names=['tiers', 'description', 'testcases'])
for tier in self.tiers.get_tiers():
if tier.get_tests():
tiers_to_run.append(tier)
- msg.add_row([tier.get_name(), tier.get_order(),
+ msg.add_row([tier.get_name(),
textwrap.fill(tier.description, width=40),
textwrap.fill(' '.join([str(x.get_name(
)) for x in tier.get_tests()]), width=40)])
diff --git a/xtesting/ci/testcases.yaml b/xtesting/ci/testcases.yaml
index 802708d0..f74d012e 100644
--- a/xtesting/ci/testcases.yaml
+++ b/xtesting/ci/testcases.yaml
@@ -2,7 +2,6 @@
tiers:
-
name: samples
- order: 1
description: ''
testcases:
-
diff --git a/xtesting/ci/tier_builder.py b/xtesting/ci/tier_builder.py
index 747d2263..2b212205 100644
--- a/xtesting/ci/tier_builder.py
+++ b/xtesting/ci/tier_builder.py
@@ -43,7 +43,7 @@ class TierBuilder():
del self.tier_objects[:]
for dic_tier in self.dic_tier_array:
tier = tier_handler.Tier(
- name=dic_tier['name'], order=dic_tier['order'],
+ name=dic_tier['name'],
description=dic_tier.get('description', ''))
for dic_testcase in dic_tier['testcases']:
testcase = tier_handler.TestCase(
diff --git a/xtesting/ci/tier_handler.py b/xtesting/ci/tier_handler.py
index 8359d91c..6f78f202 100644
--- a/xtesting/ci/tier_handler.py
+++ b/xtesting/ci/tier_handler.py
@@ -36,11 +36,10 @@ def split_text(text, max_len):
class Tier():
- def __init__(self, name, order, description=""):
+ def __init__(self, name, description=""):
self.tests_array = []
self.skipped_tests_array = []
self.name = name
- self.order = order
self.description = description
def add_test(self, testcase):
@@ -80,17 +79,13 @@ class Tier():
def get_name(self):
return self.name
- def get_order(self):
- return self.order
-
def __str__(self):
msg = prettytable.PrettyTable(
header_style='upper', padding_width=5,
- field_names=['tiers', 'order', 'description',
+ field_names=['tiers', 'description',
'testcases'])
msg.add_row(
- [self.name, self.order,
- textwrap.fill(self.description, width=40),
+ [self.name, textwrap.fill(self.description, width=40),
textwrap.fill(' '.join([str(x.get_name(
)) for x in self.get_tests()]), width=40)])
return msg.get_string()
diff --git a/xtesting/tests/unit/ci/test_tier_builder.py b/xtesting/tests/unit/ci/test_tier_builder.py
index 70a7951a..70b5aeae 100644
--- a/xtesting/tests/unit/ci/test_tier_builder.py
+++ b/xtesting/tests/unit/ci/test_tier_builder.py
@@ -30,8 +30,7 @@ class TierBuilderTesting(unittest.TestCase):
'blocking': 'test_blocking', 'description': 'test_desc',
'project_name': 'project_name'}
self.dic_tier = {
- 'name': 'test_tier', 'order': 'test_order',
- 'description': 'test_desc',
+ 'name': 'test_tier', 'description': 'test_desc',
'testcases': [self.testcase, self.testcase_disabled]}
self.mock_yaml = mock.Mock()
attrs = {'get.return_value': [self.dic_tier]}
@@ -94,7 +93,6 @@ class TierBuilderTesting(unittest.TestCase):
def test_str(self):
message = str(self.tierbuilder)
self.assertTrue('test_tier' in message)
- self.assertTrue('test_order' in message)
self.assertTrue('test_desc' in message)
self.assertTrue('test_name' in message)
diff --git a/xtesting/tests/unit/ci/test_tier_handler.py b/xtesting/tests/unit/ci/test_tier_handler.py
index 2c48ac98..5ee62c4f 100644
--- a/xtesting/tests/unit/ci/test_tier_handler.py
+++ b/xtesting/tests/unit/ci/test_tier_handler.py
@@ -22,8 +22,7 @@ class TierHandlerTesting(unittest.TestCase):
self.test = mock.Mock()
attrs = {'get_name.return_value': 'test_name'}
self.test.configure_mock(**attrs)
- self.tier = tier_handler.Tier(
- 'test_tier', 'test_order', 'test_desc')
+ self.tier = tier_handler.Tier('test_tier', 'test_desc')
self.testcase = tier_handler.TestCase(
'test_name', 'true', False, 'test_criteria',
True, description='test_desc', project='project_name')
@@ -67,9 +66,6 @@ class TierHandlerTesting(unittest.TestCase):
def test_get_name(self):
self.assertEqual(self.tier.get_name(), 'test_tier')
- def test_get_order(self):
- self.assertEqual(self.tier.get_order(), 'test_order')
-
def test_testcase_get_name(self):
self.assertEqual(self.tier.get_name(), 'test_tier')
@@ -85,9 +81,6 @@ class TierHandlerTesting(unittest.TestCase):
def test_testcase_get_project(self):
self.assertEqual(self.testcase.get_project(), 'project_name')
- def test_testcase_get_order(self):
- self.assertEqual(self.tier.get_order(), 'test_order')
-
if __name__ == "__main__":
logging.disable(logging.CRITICAL)