aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sfc/tests/functest/sfc_parent_function.py10
-rw-r--r--sfc/tests/functest/sfc_symmetric_chain.py6
2 files changed, 10 insertions, 6 deletions
diff --git a/sfc/tests/functest/sfc_parent_function.py b/sfc/tests/functest/sfc_parent_function.py
index 24ddd2e8..6161ae67 100644
--- a/sfc/tests/functest/sfc_parent_function.py
+++ b/sfc/tests/functest/sfc_parent_function.py
@@ -408,11 +408,13 @@ class SfcCommonTestCase(object):
return results
- def present_results_blocked_port_http(self, testcase_config):
+ def present_results_blocked_port_http(self, testcase_config,
+ test='HTTP'):
"""Check whether the connection between server and client using
HTTP protocol and for a specific port is blocked or not.
:param testcase_config: The config input of the test case
+ :param test: custom test string to print on result summary
:return: The results for the specific action of the scenario
"""
@@ -420,14 +422,14 @@ class SfcCommonTestCase(object):
logger.info("Test if HTTP from port %s doesn't work" % allowed_port)
if test_utils.is_http_blocked(
self.client_floating_ip, self.server_ip, allowed_port):
- results.add_to_summary(2, "PASS", "HTTP uplink blocked")
+ results.add_to_summary(2, "PASS", test + " blocked")
else:
- error = ('\033[91mTEST [FAILED] ==> HTTP BLOCKED\033[0m')
+ error = ('\033[91mTEST [FAILED] ==> HTTP WORKS\033[0m')
logger.error(error)
test_utils.capture_ovs_logs(
self.ovs_logger, self.controller_clients, self.compute_clients,
error)
- results.add_to_summary(2, "FAIL", "HTTP works")
+ results.add_to_summary(2, "FAIL", test + " works")
return results
diff --git a/sfc/tests/functest/sfc_symmetric_chain.py b/sfc/tests/functest/sfc_symmetric_chain.py
index 309d0dbc..7c453b59 100644
--- a/sfc/tests/functest/sfc_symmetric_chain.py
+++ b/sfc/tests/functest/sfc_symmetric_chain.py
@@ -116,14 +116,16 @@ class SfcSymmetricChain(sfc_parent_function.SfcCommonTestCase):
self.vxlan_start_interface(self.fips_sfs[0], 'eth0', 'eth1', "80")
self.vxlan_start_interface(self.fips_sfs[0], 'eth1', 'eth0', None)
- results = self.present_results_blocked_port_http(self.testcase_config)
+ results = self.present_results_blocked_port_http(self.testcase_config,
+ 'HTTP uplink')
self.vxlan_blocking_stop(self.fips_sfs[0])
self.vxlan_start_interface(self.fips_sfs[0], 'eth0', 'eth1', None)
self.vxlan_start_interface(self.fips_sfs[0], 'eth1', 'eth0',
self.testcase_config.source_port)
- results = self.present_results_blocked_port_http(self.testcase_config)
+ results = self.present_results_blocked_port_http(self.testcase_config,
+ 'HTTP downlink')
self.vxlan_blocking_stop(self.fips_sfs[0])
self.vxlan_start_interface(self.fips_sfs[0], 'eth0', 'eth1', None)