From 59324f72a7523f0831952f7d0997bde735864e9b Mon Sep 17 00:00:00 2001 From: Jamo Luhrsen Date: Fri, 21 Jul 2017 11:42:15 -0700 Subject: [PATCH] Use openstack cli instead of nova console-log cli Change-Id: Ida40d777d99cd7fe1e38edaece1fc781814bccee Signed-off-by: Jamo Luhrsen --- csit/libraries/OpenStackOperations.robot | 8 ++++---- .../netvirt/Netvirt_Vpnservice/01_basic_vpnservice.robot | 2 +- .../Netvirt_Vpnservice/03_basic_ipv6_vpnservice.robot | 2 +- csit/suites/netvirt/Netvirt_Vpnservice/ARP_Learning.robot | 2 +- .../netvirt/Netvirt_Vpnservice/BFD_Monitoring.robot | 2 +- csit/suites/openstack/clustering/01_l2_tests.robot | 2 +- csit/suites/openstack/clustering/02_l3_tests.robot | 2 +- csit/suites/openstack/connectivity/01_l2_tests.robot | 2 +- csit/suites/openstack/connectivity/02_l3_tests.robot | 2 +- .../connectivity/03_external_network_tests.robot | 2 +- .../openstack/connectivity/04_security_group_tests.robot | 2 +- csit/suites/openstack/extensions/sfc.robot | 2 +- 12 files changed, 15 insertions(+), 15 deletions(-) diff --git a/csit/libraries/OpenStackOperations.robot b/csit/libraries/OpenStackOperations.robot index 19fc4be34c..b937e6b0e8 100644 --- a/csit/libraries/OpenStackOperations.robot +++ b/csit/libraries/OpenStackOperations.robot @@ -322,7 +322,7 @@ Poll VM Is ACTIVE Collect VM IP Addresses [Arguments] ${fail_on_none} @{vm_list} - [Documentation] Using nova console-log on the provided ${vm_list} to search for the string "obtained" which + [Documentation] Using the console-log on the provided ${vm_list} to search for the string "obtained" which ... correlates to the instance receiving it's IP address via DHCP. Also retrieved is the ip of the nameserver ... if available in the console-log output. The keyword will also return a list of the learned ips as it ... finds them in the console log output, and will have "None" for Vms that no ip was found. @@ -353,12 +353,12 @@ Collect VM IP Addresses Collect VM IPv6 SLAAC Addresses [Arguments] ${fail_on_none} ${prefix} @{vm_list} - [Documentation] Using nova console-log on the provided ${vm_list} to search for the string "inet6" which + [Documentation] Using the console-log on the provided ${vm_list} to search for the string "inet6" which ... correlates to the instance generated IPv6 address, based on the ${prefix} received from ODL (SLAAC mode). ${ip_list} Create List @{EMPTY} : FOR ${vm} IN @{vm_list} \ Log ${vm} - \ ${rc} ${vm_ip_line}= Run And Return Rc And Output nova console-log ${vm} | grep -i "inet6" + \ ${rc} ${vm_ip_line}= Run And Return Rc And Output openstack console log show ${vm} | grep -i "inet6" \ Log ${vm_ip_line} \ Log ${rc} \ @{vm_ip_list} Get Regexp Matches ${vm_ip_line} ${prefix} @@ -374,7 +374,7 @@ View Vm Console [Arguments] ${vm_instance_names} [Documentation] View Console log of the created vm instances using nova show. : FOR ${VmElement} IN @{vm_instance_names} - \ ${rc} ${output}= Run And Return Rc And Output nova show ${VmElement} + \ ${rc} ${output}= Run And Return Rc And Output openstack server show ${VmElement} \ Log ${output} \ Should Not Be True ${rc} \ ${rc} ${output}= Run And Return Rc And Output openstack console log show ${VmElement} diff --git a/csit/suites/netvirt/Netvirt_Vpnservice/01_basic_vpnservice.robot b/csit/suites/netvirt/Netvirt_Vpnservice/01_basic_vpnservice.robot index 666211bbf7..3b9f60e069 100644 --- a/csit/suites/netvirt/Netvirt_Vpnservice/01_basic_vpnservice.robot +++ b/csit/suites/netvirt/Netvirt_Vpnservice/01_basic_vpnservice.robot @@ -100,7 +100,7 @@ Create Nova VMs ${LOOP_COUNT} Get Length ${VM_INSTANCES_NET10} : 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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Log ${VM_IP_NET10} Set Suite Variable ${VM_IP_NET10} Log ${VM_IP_NET20} diff --git a/csit/suites/netvirt/Netvirt_Vpnservice/03_basic_ipv6_vpnservice.robot b/csit/suites/netvirt/Netvirt_Vpnservice/03_basic_ipv6_vpnservice.robot index 6eb21ac777..28dcdea776 100644 --- a/csit/suites/netvirt/Netvirt_Vpnservice/03_basic_ipv6_vpnservice.robot +++ b/csit/suites/netvirt/Netvirt_Vpnservice/03_basic_ipv6_vpnservice.robot @@ -136,7 +136,7 @@ Create Nova VMs ${LOOP_COUNT} Get Length ${VM_INSTANCES_NET10} : 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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Log ${VM_IP_NET10} Set Suite Variable ${VM_IP_NET10} Log ${VM_IP_NET20} diff --git a/csit/suites/netvirt/Netvirt_Vpnservice/ARP_Learning.robot b/csit/suites/netvirt/Netvirt_Vpnservice/ARP_Learning.robot index a6f8b8681a..b73529b961 100644 --- a/csit/suites/netvirt/Netvirt_Vpnservice/ARP_Learning.robot +++ b/csit/suites/netvirt/Netvirt_Vpnservice/ARP_Learning.robot @@ -35,7 +35,7 @@ TC00 Verify Setup ${LOOP_COUNT} Get Length ${VM_INSTANCES_NET1} : 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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Set Suite Variable ${VM_IP_NET1} Set Suite Variable ${VM_IP_NET2} Set Suite Variable ${VM_IP_NET3} diff --git a/csit/suites/netvirt/Netvirt_Vpnservice/BFD_Monitoring.robot b/csit/suites/netvirt/Netvirt_Vpnservice/BFD_Monitoring.robot index 353cae350d..119b642ac1 100644 --- a/csit/suites/netvirt/Netvirt_Vpnservice/BFD_Monitoring.robot +++ b/csit/suites/netvirt/Netvirt_Vpnservice/BFD_Monitoring.robot @@ -275,7 +275,7 @@ Verify VMs received IP ${LOOP_COUNT} Get Length ${VM_INSTANCES_NET1} : 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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Log ${VM_IP_NET1} Log ${VM_IP_NET2} Should Not Contain ${VM_IP_NET2} None diff --git a/csit/suites/openstack/clustering/01_l2_tests.robot b/csit/suites/openstack/clustering/01_l2_tests.robot index 13fb553ec6..dbc2c606f4 100644 --- a/csit/suites/openstack/clustering/01_l2_tests.robot +++ b/csit/suites/openstack/clustering/01_l2_tests.robot @@ -126,7 +126,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ 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} Should Not Contain ${NET1_VM_IPS} None diff --git a/csit/suites/openstack/clustering/02_l3_tests.robot b/csit/suites/openstack/clustering/02_l3_tests.robot index a033fd0d5b..e76f8913ef 100644 --- a/csit/suites/openstack/clustering/02_l3_tests.robot +++ b/csit/suites/openstack/clustering/02_l3_tests.robot @@ -85,7 +85,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Set Suite Variable ${NET1_L3_VM_IPS} Set Suite Variable ${NET2_L3_VM_IPS} Set Suite Variable ${NET1_DHCP_IP} diff --git a/csit/suites/openstack/connectivity/01_l2_tests.robot b/csit/suites/openstack/connectivity/01_l2_tests.robot index 507d58c9e9..492bdce84d 100644 --- a/csit/suites/openstack/connectivity/01_l2_tests.robot +++ b/csit/suites/openstack/connectivity/01_l2_tests.robot @@ -81,7 +81,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ 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} Should Not Contain ${NET1_VM_IPS} None diff --git a/csit/suites/openstack/connectivity/02_l3_tests.robot b/csit/suites/openstack/connectivity/02_l3_tests.robot index a5253bce06..39b8cfa5e9 100644 --- a/csit/suites/openstack/connectivity/02_l3_tests.robot +++ b/csit/suites/openstack/connectivity/02_l3_tests.robot @@ -90,7 +90,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Set Suite Variable ${NET1_L3_VM_IPS} Set Suite Variable ${NET1_DHCP_IP} Set Suite Variable ${NET2_L3_VM_IPS} diff --git a/csit/suites/openstack/connectivity/03_external_network_tests.robot b/csit/suites/openstack/connectivity/03_external_network_tests.robot index 2a638fa944..6c7d7de8c2 100644 --- a/csit/suites/openstack/connectivity/03_external_network_tests.robot +++ b/csit/suites/openstack/connectivity/03_external_network_tests.robot @@ -68,7 +68,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ 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} Should Not Contain ${FLOATING_VM_IPS} None diff --git a/csit/suites/openstack/connectivity/04_security_group_tests.robot b/csit/suites/openstack/connectivity/04_security_group_tests.robot index edc4baf448..e9aee5fdba 100644 --- a/csit/suites/openstack/connectivity/04_security_group_tests.robot +++ b/csit/suites/openstack/connectivity/04_security_group_tests.robot @@ -75,7 +75,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ 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 ${NET1_DHCP_IP} Should Not Contain ${NET1_VM_IPS} None diff --git a/csit/suites/openstack/extensions/sfc.robot b/csit/suites/openstack/extensions/sfc.robot index f796d90e73..94a556a1a1 100644 --- a/csit/suites/openstack/extensions/sfc.robot +++ b/csit/suites/openstack/extensions/sfc.robot @@ -66,7 +66,7 @@ Check Vm Instances Have Ip Address ${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 nova console-log @{VM_INSTANCES}[${index}] 30s + \ Run Keyword If '${status}' == 'FAIL' Write Commands Until Prompt openstack console log show @{VM_INSTANCES}[${index}] 30s Set Suite Variable ${NET1_VM_IPS} Should Not Contain ${NET1_VM_IPS} None Should Not Contain ${NET1_DHCP_IP} None -- 2.36.6