summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sfc/tests/functest/config.yaml5
-rw-r--r--sfc/tests/functest/run_tests.py12
2 files changed, 12 insertions, 5 deletions
diff --git a/sfc/tests/functest/config.yaml b/sfc/tests/functest/config.yaml
index 1e241cdf..bc8cbc3a 100644
--- a/sfc/tests/functest/config.yaml
+++ b/sfc/tests/functest/config.yaml
@@ -20,6 +20,7 @@ defaults:
testcases:
sfc_two_chains_SSH_and_HTTP:
enabled: true
+ order: 1
description: "ODL-SFC tests"
testname_db: "sfc_two_chains_SSH_and_HTTP"
net_name: example-net
@@ -33,6 +34,7 @@ testcases:
sfc_one_chain_two_service_functions_different_computes:
enabled: true
+ order: 0
description: "ODL-SFC Testing SFs in different computes"
testname_db: "sfc_one_chain_two_service_functions_different_computes"
net_name: example-net
@@ -45,7 +47,8 @@ testcases:
test_vnfd_blue: "test2-vnfd2.yaml"
sfc_symmetric_chain:
- enabled: false
+ enabled: false
+ order: 2
description: "Verify the behavior of a symmetric service chain"
testname_db: "sfc_symmetric_chain"
net_name: example-net
diff --git a/sfc/tests/functest/run_tests.py b/sfc/tests/functest/run_tests.py
index 6ad6bb41..204dd3a9 100644
--- a/sfc/tests/functest/run_tests.py
+++ b/sfc/tests/functest/run_tests.py
@@ -23,6 +23,8 @@ import opnfv.utils.ovs_logger as ovs_log
import sfc.lib.cleanup as sfc_cleanup
import sfc.lib.config as sfc_config
import sfc.lib.utils as sfc_utils
+
+from collections import OrderedDict
from opnfv.deployment.factory import Factory as DeploymentFactory
@@ -91,14 +93,16 @@ def main():
config_yaml = yaml.safe_load(f)
testcases = config_yaml.get("testcases")
+ testcases_ordered = OrderedDict(sorted(testcases.items(),
+ key=lambda x: x[1]['order']))
overall_details = {}
overall_status = "FAIL"
overall_start_time = time.time()
- for testcase in testcases:
- if testcases[testcase]['enabled']:
+ for testcase, test_cfg in testcases_ordered.items():
+ if test_cfg['enabled']:
test_name = testcase
- test_descr = testcases[testcase]['description']
- test_name_db = testcases[testcase]['testname_db']
+ test_descr = test_cfg['description']
+ test_name_db = test_cfg['testname_db']
title = ("Running '%s - %s'" %
(test_name, test_descr))
logger.info(title)