aboutsummaryrefslogtreecommitdiffstats
path: root/ice_validator/tests/conftest.py
diff options
context:
space:
mode:
authorLovett, Trevor <trevor.lovett@att.com>2019-02-07 10:46:33 -0800
committerLovett, Trevor (tl2972) <tl2972@att.com>2019-02-08 12:41:46 -0600
commit981e09ed2538cd187b31e66f8c73792fb8d246eb (patch)
treee0262e53ffe33ab39e8081c285bc316c486fb20c /ice_validator/tests/conftest.py
parent20c6955caddbb6e126755bbf4cc2412279d0a11f (diff)
[VVP] Fixing internal network check
The test_neutron_port_internal_network test is intended to check that internal networks referenced in **incremental** modules are defined and exported in the base template. The current version of the test applies this check to nested modules as well causing false violations to be flagged. Issue-ID: VVP-163 Change-Id: I42cc81acf0cc2b6827ae8cf4e9a7faa4af91f9b4 Signed-off-by: Lovett, Trevor (tl2972) <tl2972@att.com>
Diffstat (limited to 'ice_validator/tests/conftest.py')
-rw-r--r--ice_validator/tests/conftest.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/ice_validator/tests/conftest.py b/ice_validator/tests/conftest.py
index 4668045..3ab1aba 100644
--- a/ice_validator/tests/conftest.py
+++ b/ice_validator/tests/conftest.py
@@ -284,7 +284,7 @@ class TestResult:
return self.item.funcargs["yaml_files"]
else:
parts = self.result.nodeid.split("[")
- return "" if len(parts) == 1 else parts[1][:-1]
+ return [""] if len(parts) == 1 else [parts[1][:-1]]
def _get_error_message(self):
"""
@@ -1041,9 +1041,9 @@ def build_rst_json(reqs):
else:
# Creates links in RST format to requirements and test cases
if values["test_case"]:
- val_list = re.findall(r'(?<=\.).*', values["test_case"])
- val = TEST_SCRIPT_SITE + val_list[0] + ".py"
- rst_value = ("`" + val_list[0] + " <" + val + ">`_")
+ mod = values["test_case"].split(".")[-1]
+ val = TEST_SCRIPT_SITE + mod + ".py"
+ rst_value = ("`" + mod + " <" + val + ">`_")
title = "`" + values["id"] + " <" + VNFRQTS_ID_URL + values["docname"].replace(" ", "%20") + ".html#" + values["id"] + ">`_"
data[key].update({'full_title': title, 'test_case': rst_value})
else: