Reduce logging in collect ips 54/65454/16
authorSam Hague <shague@redhat.com>
Sun, 12 Nov 2017 01:02:51 +0000 (20:02 -0500)
committerJamo Luhrsen <jluhrsen@redhat.com>
Mon, 13 Nov 2017 19:01:38 +0000 (19:01 +0000)
Created a new VM Collect IP keyword that reduces the
amount of logging and works faster.

Problems in old keyword:
- logged the whole console multiple times, per vm check and per
operation
- ran Verify Active extra times
- different suites replicated using code

This patch:
- moves all the common wrapping code to a single keyword
- reduces the extra Active calls
- reduces the console to a single time per vm check
- removed console log on error since the log is always captured
during the attempt to get the addresses already

This looks to have reduced the time in half for retrieving the
addresses as well as reducing the multiple loggin of long
console logs.

Only converted the connectivity suite and left the old keyword
in place. The next patches will convert the other suites.

Change-Id: I042c137165eae95946fa5197fbb52b1b85312a00
Signed-off-by: Sam Hague <shague@redhat.com>
csit/libraries/OpenStackOperations.robot
csit/suites/openstack/connectivity/01_l2_tests.robot
csit/suites/openstack/connectivity/02_l3_tests.robot
csit/suites/openstack/connectivity/03_external_network_tests.robot
csit/suites/openstack/connectivity/04_security_group_tests.robot
csit/variables/Variables.robot

index 14e80a8fbf61bc9b1f60cc68f250f6dba0013174..fcdf2f9596d445117a861f32c7b909218131beec 100644 (file)
@@ -296,7 +296,7 @@ Verify VM Is ACTIVE
     [Arguments]    ${vm_name}
     [Documentation]    Run these commands to check whether the created vm instance is active or not.
     ${rc}    ${output}=    Run And Return Rc And Output    openstack server show ${vm_name} | grep OS-EXT-STS:vm_state
-    Should Not Be True    ${rc}
+    Should Be True    '${rc}' == '0'
     Should Contain    ${output}    active
 
 Poll VM Is ACTIVE
@@ -313,19 +313,14 @@ Collect VM IP Addresses
     ${ip_list}    Create List    @{EMPTY}
     : FOR    ${vm}    IN    @{vm_list}
     \    ${rc}    ${vm_ip_line}=    Run And Return Rc And Output    openstack console log show ${vm} | grep -i "obtained"
-    \    Log    ${vm_ip_line}
-    \    Log    ${rc}
     \    @{vm_ip}    Get Regexp Matches    ${vm_ip_line}    [0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}
     \    ${vm_ip_length}    Get Length    ${vm_ip}
     \    Run Keyword If    ${vm_ip_length}>0    Append To List    ${ip_list}    @{vm_ip}[0]
     \    ...    ELSE    Append To List    ${ip_list}    None
     \    ${rc}    ${dhcp_ip_line}=    Run And Return Rc And Output    openstack console log show ${vm} | grep "^nameserver"
-    \    Log    ${dhcp_ip_line}
-    \    Log    ${rc}
     \    ${dhcp_ip}    Get Regexp Matches    ${dhcp_ip_line}    [0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}
     \    ${dhcp_ip_length}    Get Length    ${dhcp_ip}
     \    Run Keyword If    ${dhcp_ip_length}<=0    Append To List    ${dhcp_ip}    None
-    \    Log    ${dhcp_ip}
     \    ${vm_console_output}=    Run    openstack console log show ${vm}
     \    Log    ${vm_console_output}
     ${dhcp_length}    Get Length    ${dhcp_ip}
@@ -335,6 +330,47 @@ Collect VM IP Addresses
     Return From Keyword If    ${dhcp_length}==0    ${ip_list}    ${EMPTY}
     [Return]    ${ip_list}    ${dhcp_ip}
 
+Get Match
+    [Arguments]    ${text}    ${regexp}
+    [Documentation]    Wrapper around Get Regexp Matches to return None if not found or the first match if found.
+    @{matches} =    String.Get Regexp Matches    ${text}    ${regexp}
+    ${matches_length} =    Get Length    ${matches}
+    BuiltIn.Set Test Variable    ${match}    None
+    BuiltIn.Run Keyword If    ${matches_length} > 0    BuiltIn.Set Test Variable    ${match}    @{matches}[0]
+    [Return]    ${match}
+
+Get VM IP
+    [Arguments]    ${fail_on_none}    ${vm}
+    [Documentation]    Get the vm ip address and nameserver by scraping the vm's console log.
+    ${rc}    ${vm_console_output} =    Run And Return Rc And Output    openstack console log show ${vm}
+    # TODO Add hooks to only tail the console log on subsequent runs, e.g. look for "info: initramfs:".
+    # This would drop repeatedly logging the kernel messages which are long.
+    # Also add flag to log or not
+    BuiltIn.Log    ${vm_console_output}
+    ${match} =    Get Match    ${vm_console_output}    ${REGEX_OBTAINED}
+    ${OSO_VM_IP} =    Get Match    ${match}    ${REGEX_IPV4}
+    ${match} =    Get Match    ${vm_console_output}    ${REGEX_NAMESERVER}
+    ${OSO_DHCP_IP} =    Get Match    ${match}    ${REGEX_IPV4}
+    BuiltIn.Set Test Variable    ${OSO_VM_IP}
+    BuiltIn.Set Test Variable    ${OSO_DHCP_IP}
+    BuiltIn.Run Keyword If    '${fail_on_none}' == 'true'    Should Not Contain    ${OSO_VM_IP}    None
+    BuiltIn.Run Keyword If    '${fail_on_none}' == 'true'    Should Not Contain    ${OSO_DHCP_IP}    None
+
+Get VM IPs
+    [Arguments]    @{vms}
+    [Documentation]    Get the instance IP addresses and nameserver address for the list of given vms.
+    ...    First poll for the vm instance to be in the active state, then poll for the vm ip address and nameserver.
+    ...    ${OSO_VM_IP} and ${OSO_DHCP_IP} are test variables shared with Get VM IP.
+    @{OSO_VM_IPS}    BuiltIn.Create List    @{EMPTY}
+    : FOR    ${vm}    IN    @{vms}
+    \    BuiltIn.Set Test Variable    ${OSO_VM_IP}    None
+    \    BuiltIn.Set Test Variable    ${OSO_DHCP_IP}    None
+    \    Poll VM Is ACTIVE    ${vm}
+    \    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s
+    \    Get VM IP    true    ${vm}
+    \    BuiltIn.Run Keyword If    '${OSO_VM_IP}' != 'None'    Collections.Append To List    ${OSO_VM_IPS}    ${OSO_VM_IP}
+    [Return]    @{OSO_VM_IPS}    ${OSO_DHCP_IP}
+
 Collect VM IPv6 SLAAC Addresses
     [Arguments]    ${fail_on_none}    ${prefix}    @{vm_list}
     [Documentation]    Using the console-log on the provided ${vm_list} to search for the string "inet6" which
index da102a0cf23d2688463eeaf307199de267f410f1..bb9de4e8a38cbb4b9f87b493b0723f27ffa4a1f1 100644 (file)
@@ -63,27 +63,10 @@ Create Vm Instances For l2_network_2
     Create Vm Instances    l2_network_2    ${NET_2_VM_GRP_NAME}    sg=${SECURITY_GROUP}    min=3    max=3
 
 Check Vm Instances Have Ip Address
-    [Documentation]    Test case to verify that all created VMs are ready and have received their ip addresses.
-    ...    We are polling first and longest on the last VM created assuming that if it's received it's address
-    ...    already the other instances should have theirs already or at least shortly thereafter.
-    # first, ensure all VMs are in ACTIVE state.    if not, we can just fail the test case and not waste time polling
-    # for dhcp addresses
-    : FOR    ${vm}    IN    @{NET_1_VM_INSTANCES}    @{NET_2_VM_INSTANCES}
-    \    Poll VM Is ACTIVE    ${vm}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{NET_1_VM_INSTANCES}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{NET_2_VM_INSTANCES}
-    ${NET1_VM_IPS}    ${NET1_DHCP_IP}    Collect VM IP Addresses    false    @{NET_1_VM_INSTANCES}
-    ${NET2_VM_IPS}    ${NET2_DHCP_IP}    Collect VM IP Addresses    false    @{NET_2_VM_INSTANCES}
-    ${VM_INSTANCES}=    Collections.Combine Lists    ${NET_1_VM_INSTANCES}    ${NET_2_VM_INSTANCES}
-    ${VM_IPS}=    Collections.Combine Lists    ${NET1_VM_IPS}    ${NET2_VM_IPS}
-    ${LOOP_COUNT}    Get Length    ${VM_INSTANCES}
-    : FOR    ${index}    IN RANGE    0    ${LOOP_COUNT}
-    \    ${status}    ${message}    Run Keyword And Ignore Error    Should Not Contain    @{VM_IPS}[${index}]    None
-    \    Run Keyword If    '${status}' == 'FAIL'    Write Commands Until Prompt    openstack console log show @{VM_INSTANCES}[${index}]    30s
-    Set Suite Variable    ${NET1_VM_IPS}
-    Set Suite Variable    ${NET2_VM_IPS}
+    @{NET1_VM_IPS}    ${NET1_DHCP_IP} =    Get VM IPs    @{NET_1_VM_INSTANCES}
+    @{NET2_VM_IPS}    ${NET2_DHCP_IP} =    Get VM IPs    @{NET_2_VM_INSTANCES}
+    Set Suite Variable    @{NET1_VM_IPS}
+    Set Suite Variable    @{NET2_VM_IPS}
     Should Not Contain    ${NET1_VM_IPS}    None
     Should Not Contain    ${NET2_VM_IPS}    None
     Should Not Contain    ${NET1_DHCP_IP}    None
index f4290ef9926b086e53cda319475a6f45df808f19..8f58e351b036b05a92ae2394826c07562a2d11c1 100644 (file)
@@ -19,9 +19,9 @@ Resource          ../../../variables/netvirt/Variables.robot
 ${SECURITY_GROUP}    sg-connectivity
 @{NETWORKS_NAME}    network_1    network_2    network_3
 @{SUBNETS_NAME}    subnet_1    subnet_2    subnet_3
-@{NET_1_VM_INSTANCES}    l3_instance_net_1_1    l3_instance_net_1_2    l3_instance_net_1_3
-@{NET_2_VM_INSTANCES}    l3_instance_net_2_1    l3_instance_net_2_2    l3_instance_net_2_3
-@{NET_3_VM_INSTANCES}    l3_instance_net_3_1    l3_instance_net_3_2    l3_instance_net_3_3
+@{NET_1_VM_INSTANCES}    l3_net_1_vm_1    l3_net_1_vm_2    l3_net_1_vm_3
+@{NET_2_VM_INSTANCES}    l3_net_2_vm_1    l3_net_2_vm_2    l3_net_2_vm_3
+@{NET_3_VM_INSTANCES}    l3_net_3_vm_1    l3_net_3_vm_2    l3_net_3_vm_3
 @{SUBNETS_RANGE}    50.0.0.0/24    60.0.0.0/24    70.0.0.0/24
 ${network1_vlan_id}    1236
 
@@ -69,39 +69,18 @@ Create Vm Instances For network_3
     Create Vm Instances    network_3    ${NET_3_VM_INSTANCES}    sg=${SECURITY_GROUP}
 
 Check Vm Instances Have Ip Address
-    [Documentation]    Test case to verify that all created VMs are ready and have received their ip addresses.
-    ...    We are polling first and longest on the last VM created assuming that if it's received it's address
-    ...    already the other instances should have theirs already or at least shortly thereafter.
-    # first, ensure all VMs are in ACTIVE state.    if not, we can just fail the test case and not waste time polling
-    # for dhcp addresses
-    : FOR    ${vm}    IN    @{NET_1_VM_INSTANCES}    @{NET_2_VM_INSTANCES}    @{NET_3_VM_INSTANCES}
-    \    Poll VM Is ACTIVE    ${vm}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{NET_1_VM_INSTANCES}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{NET_2_VM_INSTANCES}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{NET_3_VM_INSTANCES}
-    ${NET3_L3_VM_IPS}    ${NET3_DHCP_IP}    Collect VM IP Addresses    false    @{NET_3_VM_INSTANCES}
-    ${NET2_L3_VM_IPS}    ${NET2_DHCP_IP}    Collect VM IP Addresses    false    @{NET_2_VM_INSTANCES}
-    ${NET1_L3_VM_IPS}    ${NET1_DHCP_IP}    Collect VM IP Addresses    false    @{NET_1_VM_INSTANCES}
-    ${VM_INSTANCES}=    Collections.Combine Lists    ${NET_1_VM_INSTANCES}    ${NET_2_VM_INSTANCES}    ${NET_3_VM_INSTANCES}
-    ${VM_IPS}=    Collections.Combine Lists    ${NET1_L3_VM_IPS}    ${NET2_L3_VM_IPS}    ${NET3_L3_VM_IPS}
-    ${LOOP_COUNT}    Get Length    ${VM_INSTANCES}
-    : FOR    ${index}    IN RANGE    0    ${LOOP_COUNT}
-    \    ${status}    ${message}    Run Keyword And Ignore Error    Should Not Contain    @{VM_IPS}[${index}]    None
-    \    Run Keyword If    '${status}' == 'FAIL'    Write Commands Until Prompt    openstack console log show @{VM_INSTANCES}[${index}]    30s
+    @{NET1_L3_VM_IPS}    ${NET1_L3_DHCP_IP} =    Get VM IPs    @{NET_1_VM_INSTANCES}
+    @{NET2_L3_VM_IPS}    ${NET2_L3_DHCP_IP} =    Get VM IPs    @{NET_2_VM_INSTANCES}
+    @{NET3_L3_VM_IPS}    ${NET3_L3_DHCP_IP} =    Get VM IPs    @{NET_3_VM_INSTANCES}
     Set Suite Variable    ${NET1_L3_VM_IPS}
-    Set Suite Variable    ${NET1_DHCP_IP}
     Set Suite Variable    ${NET2_L3_VM_IPS}
-    Set Suite Variable    ${NET2_DHCP_IP}
     Set Suite Variable    ${NET3_L3_VM_IPS}
-    Set Suite Variable    ${NET3_DHCP_IP}
     Should Not Contain    ${NET1_L3_VM_IPS}    None
     Should Not Contain    ${NET2_L3_VM_IPS}    None
-    Should Not Contain    ${NET1_DHCP_IP}    None
-    Should Not Contain    ${NET2_DHCP_IP}    None
-    Should Not Contain    ${NET3_DHCP_IP}    None
+    Should Not Contain    ${NET3_L3_VM_IPS}    None
+    Should Not Contain    ${NET1_L3_DHCP_IP}    None
+    Should Not Contain    ${NET2_L3_DHCP_IP}    None
+    Should Not Contain    ${NET3_L3_DHCP_IP}    None
     [Teardown]    Run Keywords    Show Debugs    @{NET_1_VM_INSTANCES}    @{NET_2_VM_INSTANCES}    @{NET_3_VM_INSTANCES}
     ...    AND    Get Test Teardown Debugs
 
index 0d533c8a7571bc884cf560c1bfaa4d6a1a180d79..304e14431a0effb06b00eaf9f4120ed56740ba73 100644 (file)
@@ -50,31 +50,14 @@ Create Vm Instances
     OpenStackOperations.Create Vm Instances    @{NETWORKS_NAME}[0]    ${VM_INSTANCES_SNAT}    sg=${SECURITY_GROUP}
 
 Check Vm Instances Have Ip Address
-    [Documentation]    Test case to verify that all created VMs are ready and have received their ip addresses.
-    ...    We are polling first and longest on the last VM created assuming that if it's received it's address
-    ...    already the other instances should have theirs already or at least shortly thereafter.
-    # first, ensure all VMs are in ACTIVE state.    if not, we can just fail the test case and not waste time polling
-    # for dhcp addresses
-    : FOR    ${vm}    IN    @{VM_INSTANCES_FLOATING}    @{VM_INSTANCES_SNAT}
-    \    Poll VM Is ACTIVE    ${vm}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{VM_INSTANCES_FLOATING}
-    ${status}    ${message}    Run Keyword And Ignore Error    Wait Until Keyword Succeeds    60s    15s    Collect VM IP Addresses
-    ...    true    @{VM_INSTANCES_SNAT}
-    ${FLOATING_VM_IPS}    ${FLOATING_DHCP_IP}    Collect VM IP Addresses    false    @{VM_INSTANCES_FLOATING}
-    ${SNAT_VM_IPS}    ${SNAT_DHCP_IP}    Collect VM IP Addresses    false    @{VM_INSTANCES_SNAT}
-    ${VM_INSTANCES}=    Collections.Combine Lists    ${VM_INSTANCES_FLOATING}    ${VM_INSTANCES_SNAT}
-    ${VM_IPS}=    Collections.Combine Lists    ${FLOATING_VM_IPS}    ${SNAT_VM_IPS}
-    ${LOOP_COUNT}    Get Length    ${VM_INSTANCES}
-    : FOR    ${index}    IN RANGE    0    ${LOOP_COUNT}
-    \    ${status}    ${message}    Run Keyword And Ignore Error    Should Not Contain    @{VM_IPS}[${index}]    None
-    \    Run Keyword If    '${status}' == 'FAIL'    Write Commands Until Prompt    openstack console log show @{VM_INSTANCES}[${index}]    30s
-    Set Suite Variable    ${FLOATING_VM_IPS}
-    Set Suite Variable    ${SNAT_VM_IPS}
+    @{FLOATING_VM_IPS}    ${FLOATING_DHCP_IP} =    Get VM IPs    @{VM_INSTANCES_FLOATING}
+    @{SNAT_VM_IPS}    ${SNAT_DHCP_IP} =    Get VM IPs    @{VM_INSTANCES_SNAT}
+    Set Suite Variable    @{FLOATING_VM_IPS}
+    Set Suite Variable    @{SNAT_VM_IPS}
     Should Not Contain    ${FLOATING_VM_IPS}    None
     Should Not Contain    ${SNAT_VM_IPS}    None
-    Should Not Contain    @{FLOATING_DHCP_IP}[0]    None
-    Should Not Contain    @{SNAT_DHCP_IP}[0]    None
+    Should Not Contain    ${FLOATING_DHCP_IP}    None
+    Should Not Contain    ${SNAT_DHCP_IP}    None
     [Teardown]    Run Keywords    Show Debugs    @{VM_INSTANCES_FLOATING}    @{VM_INSTANCES_SNAT}
     ...    AND    Get Test Teardown Debugs
 
index 1b9ea84a95fd5f4e5e5e7eb21c14e7ee9368b758..6c1294dd48e2f59f3539d3d205d10e04bd3daa5b 100644 (file)
@@ -53,31 +53,15 @@ Create Vm Instances For network_2
     OpenStackOperations.Create Vm Instances    @{NETWORKS_NAME}[1]    ${NET_2_VM_INSTANCES}    sg=${SECURITY_GROUP}
 
 Check Vm Instances Have Ip Address
-    [Documentation]    Test case to verify that all created VMs are ready and have received their ip addresses.
-    ...    We are polling first and longest on the last VM created assuming that if it's received it's address
-    ...    already the other instances should have theirs already or at least shortly thereafter.
-    # first, ensure all VMs are in ACTIVE state.    if not, we can just fail the test case and not waste time polling
-    # for dhcp addresses
-    : FOR    ${vm}    IN    @{NET_1_VM_INSTANCES}
-    \    OpenStackOperations.Poll VM Is ACTIVE    ${vm}
-    ${status}    ${message}    BuiltIn.Run Keyword And Ignore Error    BuiltIn.Wait Until Keyword Succeeds    60s    15s    OpenStackOperations.Collect VM IP Addresses
-    ...    true    @{NET_1_VM_INSTANCES}
-    ${NET1_VM_IPS}    ${NET1_DHCP_IP}    OpenStackOperations.Collect VM IP Addresses    false    @{NET_1_VM_INSTANCES}
-    ${NET2_VM_IPS}    ${NET2_DHCP_IP}    OpenStackOperations.Collect VM IP Addresses    false    @{NET_2_VM_INSTANCES}
-    ${VM_INSTANCES}=    Collections.Combine Lists    ${NET_1_VM_INSTANCES}
-    ${VM_IPS}=    Collections.Combine Lists    ${NET1_VM_IPS}
-    ${LOOP_COUNT}    BuiltIn.Get Length    ${VM_INSTANCES}
-    : FOR    ${index}    IN RANGE    0    ${LOOP_COUNT}
-    \    ${status}    ${message}    BuiltIn.Run Keyword And Ignore Error    BuiltIn.Should Not Contain    @{VM_IPS}[${index}]    None
-    \    BuiltIn.Run Keyword If    '${status}' == 'FAIL'    DevstackUtils.Write Commands Until Prompt    openstack console log show @{VM_INSTANCES}[${index}]    30s
-    BuiltIn.Set Suite Variable    ${NET1_VM_IPS}
-    BuiltIn.Set Suite Variable    ${NET1_DHCP_IP}
-    BuiltIn.Should Not Contain    ${NET1_VM_IPS}    None
-    BuiltIn.Should Not Contain    ${NET1_DHCP_IP}    None
-    BuiltIn.Set Suite Variable    ${NET2_VM_IPS}
-    BuiltIn.Set Suite Variable    ${NET2_DHCP_IP}
-    BuiltIn.Should Not Contain    ${NET2_VM_IPS}    None
-    BuiltIn.Should Not Contain    ${NET2_DHCP_IP}    None
+    @{NET1_VM_IPS}    ${NET1_DHCP_IP} =    Get VM IPs    @{NET_1_VM_INSTANCES}
+    @{NET2_VM_IPS}    ${NET2_DHCP_IP} =    Get VM IPs    @{NET_2_VM_INSTANCES}
+    Set Suite Variable    @{NET1_VM_IPS}
+    Set Suite Variable    ${NET1_DHCP_IP}
+    Set Suite Variable    @{NET2_VM_IPS}
+    Should Not Contain    ${NET1_VM_IPS}    None
+    Should Not Contain    ${NET2_VM_IPS}    None
+    Should Not Contain    ${NET1_DHCP_IP}    None
+    Should Not Contain    ${NET2_DHCP_IP}    None
     [Teardown]    BuiltIn.Run Keywords    OpenStackOperations.Show Debugs    @{NET_1_VM_INSTANCES}
     ...    AND    OpenStackOperations.Get Test Teardown Debugs
 
@@ -145,7 +129,7 @@ Add Additional Security Group To VMs
     [Documentation]    Add an additional security group to the VMs - this is done to test a different logic put in place for ports with multiple SGs
     OpenStackOperations.Security Group Create Without Default Security Rules    additional-sg
     #TODO Remove this after the Newton jobs are removed, Openstack CLI with Newton lacks support to configure rule with remote_ip_prefix
-    OpenStackOperations.Neutron Security Group Rule Create Legacy Cli    additional-sg    direction=ingress    protocol=icmp    remote_ip_prefix=@{NET1_DHCP_IP}[0]/32
+    OpenStackOperations.Neutron Security Group Rule Create Legacy Cli    additional-sg    direction=ingress    protocol=icmp    remote_ip_prefix=${NET1_DHCP_IP}/32
     OpenStackOperations.Neutron Security Group Show    additional-sg
     : FOR    ${vm}    IN    @{NET_1_VM_INSTANCES}
     \    OpenStackOperations.Add Security Group To VM    ${vm}    additional-sg
@@ -180,7 +164,7 @@ No Ping From DHCP To Vm Instance2 With Additional Security Group Rules Removed
     OpenStackOperations.Ping From DHCP Should Not Succeed    @{NETWORKS_NAME}[0]    @{NET1_VM_IPS}[1]
 
 Add The Rules To Additional Security Group Again
-    OpenStackOperations.Neutron Security Group Rule Create Legacy Cli    additional-sg    direction=ingress    protocol=icmp    remote_ip_prefix=@{NET1_DHCP_IP}[0]/32
+    OpenStackOperations.Neutron Security Group Rule Create Legacy Cli    additional-sg    direction=ingress    protocol=icmp    remote_ip_prefix=${NET1_DHCP_IP}/32
 
 Ping From DHCP To Vm Instance1 After Rules Are Added Again
     [Documentation]    Check reachability of vm instances by pinging to them from DHCP.
index ad8802c1be224700f846c29fc77425a718edc33b..73e91f278bbb430e1fbe38ccbe96c38b8fb4e2e9 100644 (file)
@@ -147,6 +147,9 @@ ${PREDEFINE_ROLE_URI}    /restconf/config/nemo-user:user-roles    # FIXME: Move
 ${PREFIX}         http://${ODL_SYSTEM_IP}:${PORT}    # Deprecated. FIXME: Name is to generic. Eradicate.
 ${PROTOCOL_LOG_LEVEL}    ${DEFAULT_PROTOCOL_LOG_LEVEL}    # Some suites temporarily override org.opendaylight.protocol Karaf log level to this value.
 ${PWD}            ${ODL_RESTCONF_PASSWORD}    # Deprecated. FIXME: Eradicate.
+${REGEX_IPV4}     [0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}
+${REGEX_NAMESERVER}    nameserver [0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}
+${REGEX_OBTAINED}    [0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3} obtained
 ${REGISTER_TENANT_URI}    /restconf/operations/nemo-intent:register-user    # FIXME: Move to a separate Nemo-related Resource and add description.
 ${RESTCONFPORT}    8181    # Primary port for ODL RESTCONF, although 8080 should also work.
 ${RESTCONFPORT_TLS}    8443    # Port for ODL RESTCONF Secure (TLS) operations