aboutsummaryrefslogtreecommitdiffstats
path: root/sfc/unit_tests
diff options
context:
space:
mode:
authorManuel Buil <mbuil@suse.com>2018-10-26 17:00:41 +0200
committerManuel Buil <mbuil@suse.com>2018-10-26 17:17:11 +0200
commitfe7d96a708927b299ddb939f854b09b3452c5304 (patch)
tree7edbf2542da085571fb18631c4942bb1cb66cde5 /sfc/unit_tests
parent471a2422aa270ebcee562ee7389adffa868f872f (diff)
Add a bit more data to the logging message
In case of failures, it is hard to understand for what vnf the port pair was being created when things went wrong Change-Id: I1cfa2553318d910535d45910b2a46d75b2f7926a Signed-off-by: Manuel Buil <mbuil@suse.com>
Diffstat (limited to 'sfc/unit_tests')
-rw-r--r--sfc/unit_tests/unit/lib/test_openstack_utils.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/sfc/unit_tests/unit/lib/test_openstack_utils.py b/sfc/unit_tests/unit/lib/test_openstack_utils.py
index 2407415e..595aed0e 100644
--- a/sfc/unit_tests/unit/lib/test_openstack_utils.py
+++ b/sfc/unit_tests/unit/lib/test_openstack_utils.py
@@ -676,7 +676,7 @@ class SfcOpenStackUtilsTesting(unittest.TestCase):
"""
mock_vm_ins = mock_vm.return_value
mock_vm_ins.name = 'vm'
- log_calls_info = [call('Creating the port pairs...')]
+ log_calls_info = [call('Creating the port pairs for vm')]
log_calls_err = [call('Only SFs with one or two ports are supported')]
exception_message = "Failed to create port pairs"
vnf_ports = ['p1', 'p2', 'p3']
@@ -698,7 +698,7 @@ class SfcOpenStackUtilsTesting(unittest.TestCase):
"""
mock_vm_ins = mock_vm.return_value
mock_vm_ins.name = 'vm'
- log_calls_info = [call('Creating the port pairs...')]
+ log_calls_info = [call('Creating the port pairs for vm')]
log_calls_warn = [call('Chain creation failed due to port pair '
'creation failed for vnf %(vnf)s', {'vnf': 'vm'})]
mock_port_ins = mock_port.return_value
@@ -724,8 +724,8 @@ class SfcOpenStackUtilsTesting(unittest.TestCase):
"""
mock_vm_ins = mock_vm.return_value
mock_vm_ins.name = 'vm'
- log_calls_info = [call('Creating the port pairs...'),
- call('Creating the port pair groups...')]
+ log_calls_info = [call('Creating the port pairs for vm'),
+ call('Creating the port pair groups for vm')]
log_calls_warn = [call('Chain creation failed due to port pair group '
'creation failed for vnf %(vnf)', 'vm')]
mock_port_ins = mock_port.return_value
@@ -747,8 +747,8 @@ class SfcOpenStackUtilsTesting(unittest.TestCase):
Checks the create_port_groups when everything goes as expected
"""
- log_calls_info = [call('Creating the port pairs...'),
- call('Creating the port pair groups...')]
+ log_calls_info = [call('Creating the port pairs for vm'),
+ call('Creating the port pair groups for vm')]
mock_port_ins = mock_port.return_value
mock_port_ins.id = '123abc'
mock_osvm_ins = mock_osvm.return_value