aboutsummaryrefslogtreecommitdiffstats
path: root/functest/opnfv_tests/vnf/ims
diff options
context:
space:
mode:
authorAlex Yang <yangyang1@zte.com.cn>2017-09-03 14:36:11 +0800
committerAlex Yang <yangyang1@zte.com.cn>2017-09-03 14:36:11 +0800
commitfff71f30410d33919e9ceddd8e5ff87f7e6630d5 (patch)
tree42e23b587d630a548d81ede6c44d4ceb8e88cb18 /functest/opnfv_tests/vnf/ims
parent9f0b0675da1b8f4e6edb277492bf6b2f747721b8 (diff)
Fix get_port_by_name in ims testcases
Now there isn't a function named get_port_by_name in [1]. Use get_port to replace it. [1]: https://git.opnfv.org/snaps/tree/snaps/openstack/utils/neutron_utils.py Change-Id: Ide5d6b497092f66abe6b0452841007808ee908e6 Signed-off-by: Alex Yang <yangyang1@zte.com.cn>
Diffstat (limited to 'functest/opnfv_tests/vnf/ims')
-rw-r--r--functest/opnfv_tests/vnf/ims/orchestra_clearwaterims.py5
-rw-r--r--functest/opnfv_tests/vnf/ims/orchestra_openims.py5
2 files changed, 6 insertions, 4 deletions
diff --git a/functest/opnfv_tests/vnf/ims/orchestra_clearwaterims.py b/functest/opnfv_tests/vnf/ims/orchestra_clearwaterims.py
index 5154dea2..216632ee 100644
--- a/functest/opnfv_tests/vnf/ims/orchestra_clearwaterims.py
+++ b/functest/opnfv_tests/vnf/ims/orchestra_clearwaterims.py
@@ -661,8 +661,9 @@ class ClearwaterImsVnf(vnf.VnfOnBoarding):
try:
neutron_client = os_utils.get_neutron_client(self.creds)
self.logger.info("Deleting Open Baton Port...")
- port = snaps_utils.neutron_utils.get_port_by_name(
- neutron_client, '%s_port' % self.case_name)
+ port = snaps_utils.neutron_utils.get_port(
+ neutron_client,
+ port_name='%s_port' % self.case_name)
snaps_utils.neutron_utils.delete_port(neutron_client, port)
time.sleep(10)
except Exception as exc:
diff --git a/functest/opnfv_tests/vnf/ims/orchestra_openims.py b/functest/opnfv_tests/vnf/ims/orchestra_openims.py
index 45440704..6c9628f7 100644
--- a/functest/opnfv_tests/vnf/ims/orchestra_openims.py
+++ b/functest/opnfv_tests/vnf/ims/orchestra_openims.py
@@ -697,8 +697,9 @@ class OpenImsVnf(vnf.VnfOnBoarding):
try:
neutron_client = os_utils.get_neutron_client(self.creds)
self.logger.info("Deleting Open Baton Port...")
- port = snaps_utils.neutron_utils.get_port_by_name(
- neutron_client, '%s_port' % self.case_name)
+ port = snaps_utils.neutron_utils.get_port(
+ neutron_client,
+ port_name='%s_port' % self.case_name)
snaps_utils.neutron_utils.delete_port(neutron_client, port)
time.sleep(10)
except Exception as exc: