Abort vping_userdata test if IP address is missing 57/58457/3
authorJuha Kosonen <juha.kosonen@nokia.com>
Tue, 12 Jun 2018 13:35:19 +0000 (16:35 +0300)
committerJuha Kosonen <juha.kosonen@nokia.com>
Wed, 13 Jun 2018 13:47:15 +0000 (16:47 +0300)
Do not start checking the result of ping test if the first instance has
no IP address.

JIRA: FUNCTEST-976

Change-Id: I2da3154e63a6a97f86efe8274be84abc437aa133
Signed-off-by: Juha Kosonen <juha.kosonen@nokia.com>
functest/opnfv_tests/openstack/vping/vping_userdata.py

index 056598d..4f9f635 100644 (file)
@@ -64,6 +64,10 @@ class VPingUserdata(vping_base.VPingBase):
         """
         Override from super
         """
+        if not self.vm1.private_v4:
+            self.logger.error("vm1: IP addr missing")
+            return testcase.TestCase.EX_TESTCASE_FAILED
+
         self.logger.info("Waiting for ping...")
         exit_code = testcase.TestCase.EX_TESTCASE_FAILED
         sec = 0