summaryrefslogtreecommitdiffstats
path: root/sdnvpn/test/functest
diff options
context:
space:
mode:
Diffstat (limited to 'sdnvpn/test/functest')
-rw-r--r--sdnvpn/test/functest/testcase_1.py8
-rw-r--r--sdnvpn/test/functest/testcase_4.py8
-rw-r--r--sdnvpn/test/functest/testcase_7.py2
-rw-r--r--sdnvpn/test/functest/testcase_8.py2
4 files changed, 10 insertions, 10 deletions
diff --git a/sdnvpn/test/functest/testcase_1.py b/sdnvpn/test/functest/testcase_1.py
index a5c1494..5aa6411 100644
--- a/sdnvpn/test/functest/testcase_1.py
+++ b/sdnvpn/test/functest/testcase_1.py
@@ -82,7 +82,7 @@ def main():
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_1)
- vm_2_ip = vm_2.networks.itervalues().next()[0]
+ vm_2_ip = test_utils.get_instance_ip(vm_2)
vm_3 = test_utils.create_instance(
nova_client,
@@ -92,7 +92,7 @@ def main():
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_2)
- vm_3_ip = vm_3.networks.itervalues().next()[0]
+ vm_3_ip = test_utils.get_instance_ip(vm_3)
vm_5 = test_utils.create_instance(
nova_client,
@@ -102,7 +102,7 @@ def main():
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_2)
- vm_5_ip = vm_5.networks.itervalues().next()[0]
+ vm_5_ip = test_utils.get_instance_ip(vm_5)
# We boot vm5 first because we need vm5_ip for vm4 userdata
u4 = test_utils.generate_ping_userdata([vm_5_ip])
@@ -115,7 +115,7 @@ def main():
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_1,
userdata=u4)
- vm_4_ip = vm_4.networks.itervalues().next()[0]
+ vm_4_ip = test_utils.get_instance_ip(vm_4)
# We boot VM1 at the end because we need to get the IPs first to generate
# the userdata
diff --git a/sdnvpn/test/functest/testcase_4.py b/sdnvpn/test/functest/testcase_4.py
index bb3ea3e..a474630 100644
--- a/sdnvpn/test/functest/testcase_4.py
+++ b/sdnvpn/test/functest/testcase_4.py
@@ -82,7 +82,7 @@ def main():
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_1)
- vm_2_ip = vm_2.networks.itervalues().next()[0]
+ vm_2_ip = test_utils.get_instance_ip(vm_2)
vm_3 = test_utils.create_instance(
nova_client,
@@ -92,7 +92,7 @@ def main():
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_2)
- vm_3_ip = vm_3.networks.itervalues().next()[0]
+ vm_3_ip = test_utils.get_instance_ip(vm_3)
vm_5 = test_utils.create_instance(
nova_client,
@@ -102,7 +102,7 @@ def main():
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_2)
- vm_5_ip = vm_5.networks.itervalues().next()[0]
+ vm_5_ip = test_utils.get_instance_ip(vm_5)
# We boot vm5 first because we need vm5_ip for vm4 userdata
u4 = test_utils.generate_ping_userdata([vm_5_ip])
@@ -115,7 +115,7 @@ def main():
secgroup_name=TESTCASE_CONFIG.secgroup_name,
compute_node=av_zone_1,
userdata=u4)
- vm_4_ip = vm_4.networks.itervalues().next()[0]
+ vm_4_ip = test_utils.get_instance_ip(vm_4)
# We boot VM1 at the end because we need to get the IPs first to generate
# the userdata
diff --git a/sdnvpn/test/functest/testcase_7.py b/sdnvpn/test/functest/testcase_7.py
index 18b6dda..3bc9afb 100644
--- a/sdnvpn/test/functest/testcase_7.py
+++ b/sdnvpn/test/functest/testcase_7.py
@@ -82,7 +82,7 @@ def main():
network_2_id,
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name)
- vm_2_ip = vm_2.networks.itervalues().next()[0]
+ vm_2_ip = test_utils.get_instance_ip(vm_2)
u1 = test_utils.generate_ping_userdata([vm_2_ip])
vm_1 = test_utils.create_instance(
diff --git a/sdnvpn/test/functest/testcase_8.py b/sdnvpn/test/functest/testcase_8.py
index 1e29bb2..1fdfa00 100644
--- a/sdnvpn/test/functest/testcase_8.py
+++ b/sdnvpn/test/functest/testcase_8.py
@@ -81,7 +81,7 @@ def main():
network_2_id,
sg_id,
secgroup_name=TESTCASE_CONFIG.secgroup_name)
- vm_2_ip = vm_2.networks.itervalues().next()[0]
+ vm_2_ip = test_utils.get_instance_ip(vm_2)
u1 = test_utils.generate_ping_userdata([vm_2_ip])
vm_1 = test_utils.create_instance(