X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;ds=sidebyside;f=tests%2Funit%2Fnetwork_services%2Fvnf_generic%2Fvnf%2Ftest_prox_vnf.py;h=e29e8ddcd849a350a60e277a6edc68464afb7c0d;hb=31b02e5b95d8b4076ef60667d051a8a1a6b072ba;hp=c88b1528c6b03fa9f7b9d49bbd06a3d206f31220;hpb=870d2ba61b4a3352ef8485c3b39690346010e89b;p=yardstick.git diff --git a/tests/unit/network_services/vnf_generic/vnf/test_prox_vnf.py b/tests/unit/network_services/vnf_generic/vnf/test_prox_vnf.py index c88b1528c..e29e8ddcd 100644 --- a/tests/unit/network_services/vnf_generic/vnf/test_prox_vnf.py +++ b/tests/unit/network_services/vnf_generic/vnf/test_prox_vnf.py @@ -85,7 +85,7 @@ class TestProxApproxVnf(unittest.TestCase): 'vpci': '0000:05:00.0', 'local_ip': '152.16.100.19', 'type': 'PCI-PASSTHROUGH', - 'vld_id': '', + 'vld_id': 'downlink_0', 'ifname': 'xe1', 'netmask': '255.255.255.0', 'dpdk_port_num': 0, @@ -104,8 +104,8 @@ class TestProxApproxVnf(unittest.TestCase): 'vpci': '0000:05:00.1', 'local_ip': '152.16.40.19', 'type': 'PCI-PASSTHROUGH', - 'vld_id': '', - 'ifname': 'xe3', + 'vld_id': 'uplink_0', + 'ifname': 'xe1', 'driver': "i40e", 'netmask': '255.255.255.0', 'dpdk_port_num': 1, @@ -348,9 +348,9 @@ class TestProxApproxVnf(unittest.TestCase): prox_approx_vnf.resource_helper = resource_helper expected = { - 'packets_in': 7, + 'packets_in': 6, 'packets_dropped': 1, - 'packets_fwd': 6, + 'packets_fwd': 7, 'collect_stats': {'core': {'result': 234}}, } result = prox_approx_vnf.collect_kpi() @@ -365,6 +365,7 @@ class TestProxApproxVnf(unittest.TestCase): prox_approx_vnf = ProxApproxVnf(NAME, deepcopy(self.VNFD0)) prox_approx_vnf.resource_helper = resource_helper prox_approx_vnf.vnfd_helper['vdu'][0]['external-interface'] = [] + prox_approx_vnf.vnfd_helper.port_pairs.interfaces = [] with self.assertRaises(RuntimeError): prox_approx_vnf.collect_kpi() @@ -375,7 +376,7 @@ class TestProxApproxVnf(unittest.TestCase): return file_path @mock.patch('yardstick.benchmark.scenarios.networking.vnf_generic.open', create=True) - @mock.patch('yardstick.network_services.vnf_generic.vnf.iniparser.open', create=True) + @mock.patch('yardstick.network_services.helpers.iniparser.open', create=True) @mock.patch(SSH_HELPER) def test_run_prox(self, ssh, *_): mock_ssh(ssh)