From: ramonsalguer Date: Mon, 15 Jun 2020 13:37:28 +0000 (+0000) Subject: Fix for Robot tests: implement adjustable timeouts for slow NS (basic_03, basic_06... X-Git-Tag: release-v8.0-start~21 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=543d706ec638b957d7917b0b9e23497d0949a975;p=osm%2Fdevops.git Fix for Robot tests: implement adjustable timeouts for slow NS (basic_03, basic_06, basic_07 Change-Id: I73f2cc91b2872b9a7a9e9cd1cc4953133d4cd24c Signed-off-by: ramonsalguer --- diff --git a/robot-systest/lib/ns_lib.robot b/robot-systest/lib/ns_lib.robot index fb4561e1..6a8c84bf 100644 --- a/robot-systest/lib/ns_lib.robot +++ b/robot-systest/lib/ns_lib.robot @@ -12,7 +12,6 @@ *** Variables *** ${success_return_code} 0 -${ns_launch_max_wait_time} 5min ${ns_launch_pol_time} 30sec ${ns_delete_max_wait_time} 1min ${ns_delete_pol_time} 15sec @@ -24,7 +23,7 @@ ${vnf_scale_pol_time} 30sec *** Keywords *** Create Network Service - [Arguments] ${nsd} ${vim_name} ${ns_name} ${ns_config} ${publickey} + [Arguments] ${nsd} ${vim_name} ${ns_name} ${ns_config} ${publickey} ${ns_launch_max_wait_time}=5min ${config_attr} Set Variable If '${ns_config}'!='${EMPTY}' --config '${ns_config}' \ ${sshkeys_attr} Set Variable If '${publickey}'!='${EMPTY}' --ssh_keys ${publickey} \ diff --git a/robot-systest/testsuite/basic_06-vnf_with_charm.robot b/robot-systest/testsuite/basic_06-vnf_with_charm.robot index b42ba277..2514ce26 100644 --- a/robot-systest/testsuite/basic_06-vnf_with_charm.robot +++ b/robot-systest/testsuite/basic_06-vnf_with_charm.robot @@ -36,6 +36,7 @@ ${vnf_member_index_2} 2 ${day_1_file_name} /home/ubuntu/first-touch ${day_2_file_name_1} /home/ubuntu/mytouch1 ${day_2_file_name_2} /home/ubuntu/mytouch2 +${ns_timeout} 15min *** Test Cases *** @@ -54,7 +55,7 @@ Create Charm NS Descriptor Instantiate Charm Network Service [Tags] charm - ${id}= Create Network Service ${nsd_name} %{VIM_TARGET} ${ns_name} ${ns_config} ${publickey} + ${id}= Create Network Service ${nsd_name} %{VIM_TARGET} ${ns_name} ${ns_config} ${publickey} ${ns_timeout} Set Suite Variable ${ns_id} ${id} diff --git a/robot-systest/testsuite/basic_07-secure_key_management.robot b/robot-systest/testsuite/basic_07-secure_key_management.robot index 98e6edfa..b0e0377c 100644 --- a/robot-systest/testsuite/basic_07-secure_key_management.robot +++ b/robot-systest/testsuite/basic_07-secure_key_management.robot @@ -34,6 +34,7 @@ ${action_name} touch ${vnf_member_index} 1 ${day_1_file_name} /home/ubuntu/first-touch ${day_2_file_name} /home/ubuntu/mytouch1 +${ns_timeout} 15min *** Test Cases *** @@ -52,7 +53,7 @@ Create Nopasswd Charm NS Descriptor Instantiate Nopasswd Charm Network Service [Tags] nopasswd - ${id}= Create Network Service ${nsd_name} %{VIM_TARGET} ${ns_name} ${ns_config} ${EMPTY} + ${id}= Create Network Service ${nsd_name} %{VIM_TARGET} ${ns_name} ${ns_config} ${EMPTY} ${ns_timeout} Set Suite Variable ${ns_id} ${id} diff --git a/robot-systest/testsuite/hackfest_multivdu.robot b/robot-systest/testsuite/hackfest_multivdu.robot index 508d11f4..7c5abeda 100644 --- a/robot-systest/testsuite/hackfest_multivdu.robot +++ b/robot-systest/testsuite/hackfest_multivdu.robot @@ -35,6 +35,7 @@ ${password} osm4u ${vnf_member_index} 1 ${vnf_ip_addr} ${EMPTY} ${ns_config} {vld: [ {name: mgmtnet, vim-network-name: %{VIM_MGMT_NET}} ] } +${wait_guard_for_vm_boot} 50s # ${ns_config} ${EMPTY} *** Test Cases *** @@ -56,7 +57,7 @@ Network Service Instance Test Run Keyword If "${status}" == "FAIL" Set Global Variable ${publickey} ${EMPTY} ${id}= Create Network Service ${nsd_name} %{VIM_TARGET} ${ns_name} ${ns_config} ${publickey} Set Suite Variable ${ns_id} ${id} - + Sleep ${wait_guard_for_vm_boot} Waiting for VM's daemons to be up and running Get Vnf Ip Address [Tags] hackfest_multivdu @@ -71,7 +72,6 @@ Test Ping Test SSH Access [Tags] hackfest_multivdu - Sleep 30s Waiting ssh daemon to be up ${status} ${message}= Run Keyword And Ignore Error Variable Should Exist ${privatekey} Run Keyword If "${status}" == "FAIL" Set Global Variable ${privatekey} ${EMPTY} Test SSH Connection ${vnf_ip_addr} ${username} ${password} ${privatekey}