... new leader is elected or should remained the same as ${old_leader}
${leader} ${followers}= Get_Leader_And_Followers_For_Shard shard_name=${shard_name} shard_type=${shard_type} member_index_list=${member_index_list} verify_restconf=${verify_restconf}
BuiltIn.Run_Keyword_If ${new_elected} BuiltIn.Should_Not_Be_Equal_As_Numbers ${old_leader} ${leader}
- BuiltIn.Run_Keyword_Unless ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_leader} ${leader}
+ BuiltIn.Run_Keyword_If not ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_leader} ${leader}
BuiltIn.Return_From_Keyword ${leader} ${followers}
Verify_Owner_And_Successors_For_Device
Should Contain ${resp.text} "source-tp":"openflow:${switch}:2"
Should Contain ${resp.text} "dest-tp":"openflow:${switch}:2"
${edge} Evaluate ${switch}==1 or ${switch}==${switches}
- Run Keyword Unless ${edge} Should Contain ${resp.text} "tp-id":"openflow:${switch}:3"
- Run Keyword Unless ${edge} Should Contain ${resp.text} "source-tp":"openflow:${switch}:3"
- Run Keyword Unless ${edge} Should Contain ${resp.text} "dest-tp":"openflow:${switch}:3
+ Run Keyword If not ${edge} Should Contain ${resp.text} "tp-id":"openflow:${switch}:3"
+ Run Keyword If not ${edge} Should Contain ${resp.text} "source-tp":"openflow:${switch}:3"
+ Run Keyword If not ${edge} Should Contain ${resp.text} "dest-tp":"openflow:${switch}:3
END
Check No Switches On Member
Start_ExaBgp ${cfg_file}
${status} ${value}= BuiltIn.Run_Keyword_And_Ignore_Error BuiltIn.Wait_Until_Keyword_Succeeds 3x 3s
... Verify_ExaBgps_Connection ${session} ${exabgp_ip} connected=${True}
- BuiltIn.Run_Keyword_Unless "${status}" == "PASS" Stop_ExaBgp
+ BuiltIn.Run_Keyword_If "${status}" != "PASS" Stop_ExaBgp
BuiltIn.Return_From_Keyword_If "${status}" == "PASS"
END
BuiltIn.Fail Unable to connect ExaBgp to ODL
Should Contain ${resp.text} "source-tp":"openflow:${switch}:2"
Should Contain ${resp.text} "dest-tp":"openflow:${switch}:2"
${edge} Evaluate ${switch}==1 or ${switch}==${switches}
- Run Keyword Unless ${edge} Should Contain ${resp.text} "tp-id":"openflow:${switch}:3"
- Run Keyword Unless ${edge} Should Contain ${resp.text} "source-tp":"openflow:${switch}:3"
- Run Keyword Unless ${edge} Should Contain ${resp.text} "dest-tp":"openflow:${switch}:3"
+ Run Keyword If not ${edge} Should Contain ${resp.text} "tp-id":"openflow:${switch}:3"
+ Run Keyword If not ${edge} Should Contain ${resp.text} "source-tp":"openflow:${switch}:3"
+ Run Keyword If not ${edge} Should Contain ${resp.text} "dest-tp":"openflow:${switch}:3"
END
Check Flows Operational Datastore
Process.Start Process Xvfb :${XVFB_PORT} -ac -screen 0 1280x1024x16
... alias=xvfb
${display}= OperatingSystem.Get Environment Variable DISPLAY ${EMPTY}
- BuiltIn.Run Keyword Unless "${display}"==":${XVFB_PORT}" Set Display Port
+ BuiltIn.Run Keyword If "${display}"!=":${XVFB_PORT}" Set Display Port
Close DLUX And Terminate XVFB Process If Running
[Documentation] Closes all browser instances and terminates Xvfb if the process is running.
... 3. Go to DLUX login URL and wait until the HTML page contains a specific element.
${status}= BuiltIn.Run Keyword And Return Status Run Keywords Open Virtual Display
... AND Selenium2Library.Open Browser ${LOGIN_URL} ${BROWSER}
- BuiltIn.Run Keyword Unless ${status} Open Headless Browser ${LOGIN_URL}
+ BuiltIn.Run Keyword If not ${status} Open Headless Browser ${LOGIN_URL}
Selenium2Library.Wait Until Page Contains Element css=div.container
Open DLUX Login Page
[Arguments] ${url}
[Documentation] Goes to the defined URL provided in an argument.
${status}= BuiltIn.Run Keyword And Return Status Selenium2Library.Location Should Be ${url}
- BuiltIn.Run Keyword Unless ${status} Selenium2Library.Go To ${url}
+ BuiltIn.Run Keyword If not ${status} Selenium2Library.Go To ${url}
Focus And Click Element
[Arguments] ${element}
BuiltIn.Should Contain ${resp.text} ${dst}
BuiltIn.Run Keyword If '${config_api_type}' == '${EMPTY}' BuiltIn.Should Contain ${resp.text} ${src}
${tunnel_interface_name} = BuiltIn.Run Keyword If "tunnel-interface-names" in "${json}" Genius.Get Tunnel Interface Name ${json["internal-tunnel"][0]} tunnel-interface-names
- ${tunnel_name_output} ${tunnel_name} = BuiltIn.Run Keyword Unless '${config_api_type}' == '${EMPTY}' BuiltIn.Should Match Regexp ${resp.text} "tunnel-name":"(tun[\\w\\d]+)"
+ ${tunnel_name_output} ${tunnel_name} = BuiltIn.Run Keyword If '${config_api_type}' != '${EMPTY}' BuiltIn.Should Match Regexp ${resp.text} "tunnel-name":"(tun[\\w\\d]+)"
${tunnel} = BuiltIn.Set Variable If '${config_api_type}' == '${EMPTY}' ${tunnel_interface_name} ${tunnel_name}
[Return] ${tunnel}
Start_GoBgp ${cfg_file}
${status} ${value}= BuiltIn.Run_Keyword_And_Ignore_Error BuiltIn.Wait_Until_Keyword_Succeeds ${connection_retries}x 15s
... Verify_GoBgps_Connection ${session} ${gobgp_ip} connected=${True}
- BuiltIn.Run_Keyword_Unless "${status}" == "PASS" Stop_GoBgp
+ BuiltIn.Run_Keyword_If "${status}" != "PASS" Stop_GoBgp
BuiltIn.Return_From_Keyword_If "${status}" == "PASS"
Verify_GoBgps_Connection
${index_list} = ClusterManagement.List_Indices_Or_All given_list=${member_index_list}
FOR ${index} IN @{index_list} # usually: 1, 2, 3.
${status} ${output} = BuiltIn.Run_Keyword_And_Ignore_Error Execute_Controller_Karaf_Command_With_Retry_On_Background log:log "ROBOT MESSAGE: ${message}" member_index=${index}
- BuiltIn.Run_Keyword_Unless ${tolerate_failure} or "${status}" == "PASS" BuiltIn.Fail ${output}
+ BuiltIn.Run_Keyword_If not ${tolerate_failure} and "${status}" != "PASS" BuiltIn.Fail ${output}
END
Log_Test_Suite_Start_To_Controller_Karaf
${response} = BuiltIn.Run_Keyword_If """${http_timeout}""" == """${EMPTY}""" RequestsLibrary.Get_Request alias=${session} uri=${uri} headers=${accept}
... ELSE RequestsLibrary.Get_Request alias=${session} uri=${uri} headers=${accept} timeout=${http_timeout}
Check_Status_Code ${response} log_response=${log_response}
- BuiltIn.Run_Keyword_Unless ${normalize_json} BuiltIn.Return_From_Keyword ${response.text}
+ BuiltIn.Run_Keyword_If not ${normalize_json} BuiltIn.Return_From_Keyword ${response.text}
${text_normalized} = norm_json.normalize_json_text ${response.text} jmes_path=${jmes_path} keys_with_volatiles=${keys_with_volatiles}
[Return] ${text_normalized}
... ELSE RequestsLibrary.Put_Request alias=${session} uri=${uri} data=${data} headers=${headers}
... timeout=${http_timeout}
Check_Status_Code ${response}
- BuiltIn.Run_Keyword_Unless ${normalize_json} BuiltIn.Return_From_Keyword ${response.text}
+ BuiltIn.Run_Keyword_If not ${normalize_json} BuiltIn.Return_From_Keyword ${response.text}
${text_normalized} = norm_json.normalize_json_text ${response.text} jmes_path=${jmes_path}
[Return] ${text_normalized}
... ELSE RequestsLibrary.Post_Request alias=${session} uri=${uri} data=${data} headers=${headers}
... timeout=${http_timeout}
Check_Status_Code ${response} additional_allowed_status_codes=${additional_allowed_status_codes} explicit_status_codes=${explicit_status_codes}
- BuiltIn.Run_Keyword_Unless ${normalize_json} BuiltIn.Return_From_Keyword ${response.text}
+ BuiltIn.Run_Keyword_If not ${normalize_json} BuiltIn.Return_From_Keyword ${response.text}
${text_normalized} = norm_json.normalize_json_text ${response.text} jmes_path=${jmes_path}
[Return] ${text_normalized}
[Documentation] Iterate over all non-isolated cluster nodes. They should return the correct constant.
FOR ${index} IN @{cs_all_indices}
BuiltIn.Run_Keyword_If "${index}" == "${cs_isolated_index}" BuiltIn.Log Node not triggered, behavior not well described, see bugs 8207, 8214.
- BuiltIn.Run_Keyword_Unless "${index}" == "${cs_isolated_index}" Verify_Singleton_Constant_On_Node ${index} ${CS_CONSTANT_PREFIX}${cs_owner}
+ BuiltIn.Run_Keyword_If "${index}" != "${cs_isolated_index}" Verify_Singleton_Constant_On_Node ${index} ${CS_CONSTANT_PREFIX}${cs_owner}
END
Isolate_Owner_And_Verify_Isolated
Start_Bgp_Peer peerip=${peerip}
${status} ${value}= BuiltIn.Run_Keyword_And_Ignore_Error BuiltIn.Wait_Until_Keyword_Succeeds 3x 3s
... Verify_Bgp_Peer_Connection ${config_session} ${TOOLS_SYSTEM_IP} connected=${True}
- BuiltIn.Run_Keyword_Unless "${status}" == "PASS" BGPSpeaker.Kill_BGP_Speaker
+ BuiltIn.Run_Keyword_If "${status}" != "PASS" BGPSpeaker.Kill_BGP_Speaker
BuiltIn.Return_From_Keyword_If "${status}" == "PASS"
END
BuiltIn.Fail Unable to connect bgp peer to ODL
[Documentation] Verify new owner was elected or remained the same.
${owner} ${successors}= Get_Present_Brt_Owner_And_Successors ${node_to_ask}
BuiltIn.Run_Keyword_If ${new_elected} BuiltIn.Should_Not_Be_Equal_As_Numbers ${old_owner} ${owner}
- BuiltIn.Run_Keyword_Unless ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_owner} ${owner}
+ BuiltIn.Run_Keyword_If not ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_owner} ${owner}
Get_Present_Brt_Owner_And_Successors
[Arguments] ${node_to_ask} ${store}=${False}
[Documentation] Verify new owner was elected or remained the same.
${owner} ${successors}= Get_Present_Brt_Owner_And_Successors ${node_to_ask}
BuiltIn.Run_Keyword_If ${new_elected} BuiltIn.Should_Not_Be_Equal_As_Numbers ${old_owner} ${owner}
- BuiltIn.Run_Keyword_Unless ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_owner} ${owner}
+ BuiltIn.Run_Keyword_If not ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_owner} ${owner}
Get_Present_Brt_Owner_And_Successors
[Arguments] ${node_to_ask} ${store}=${False}
[Documentation] Verify new owner was elected or remained the same.
${owner} ${successors}= Get_Present_Brt_Owner_And_Successors ${node_to_ask}
BuiltIn.Run_Keyword_If ${new_elected} BuiltIn.Should_Not_Be_Equal_As_Numbers ${old_owner} ${owner}
- BuiltIn.Run_Keyword_Unless ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_owner} ${owner}
+ BuiltIn.Run_Keyword_If not ${new_elected} BuiltIn.Should_Be_Equal_As_numbers ${old_owner} ${owner}
Get_Present_Brt_Owner_And_Successors
[Arguments] ${node_to_ask} ${store}=${False}
Wait For Flows
Sleep 30s
${passed} = Run Keyword And Return Status OpenFlowUtils.Wait For Flows On Switch ${GBP1} sw1
- Run Keyword Unless ${passed} Fatal Error Flows not created on sw1!
+ Run Keyword If not ${passed} Fatal Error Flows not created on sw1!
${passed} = Run Keyword And Return Status OpenFlowUtils.Wait For Flows On Switch ${GBP2} sw2
- Run Keyword Unless ${passed} Fatal Error Flows not created on sw2!
+ Run Keyword If not ${passed} Fatal Error Flows not created on sw2!
${passed} = Run Keyword And Return Status OpenFlowUtils.Wait For Flows On Switch ${GBP3} sw3
- Run Keyword Unless ${passed} Fatal Error Flows not created on sw3!
+ Run Keyword If not ${passed} Fatal Error Flows not created on sw3!
Wait For Flows
Sleep 30s
${passed} = Run Keyword And Return Status OpenFlowUtils.Wait For Flows On Switch ${GBP1} sw1
- Run Keyword Unless ${passed} Fatal Error Flows not created on sw1!
+ Run Keyword If not ${passed} Fatal Error Flows not created on sw1!
${passed} = Run Keyword And Return Status OpenFlowUtils.Wait For Flows On Switch ${GBP2} sw2
- Run Keyword Unless ${passed} Fatal Error Flows not created on sw2!
+ Run Keyword If not ${passed} Fatal Error Flows not created on sw2!
${passed} = Run Keyword And Return Status OpenFlowUtils.Wait For Flows On Switch ${GBP3} sw3
- Run Keyword Unless ${passed} Fatal Error Flows not created on sw3!
+ Run Keyword If not ${passed} Fatal Error Flows not created on sw3!
BuiltIn.Run_Keyword_If ${run_netconf_testtool_manually} BuiltIn.Set_Suite_Variable ${testtool_log} ${logfile}
FOR ${ssh_session} IN @{TOOLS_SESSIONS}
SSHKeywords.Restore_Current_Ssh_Connection_From_Index ${ssh_session}
- BuiltIn.Run_Keyword_Unless ${run_netconf_testtool_manually} Install_And_Start_Testtool device-count=1 debug=false schemas=${IOS_XE_SCHEMAS_FOLDER}
+ BuiltIn.Run_Keyword_If not ${run_netconf_testtool_manually} Install_And_Start_Testtool device-count=1 debug=false schemas=${IOS_XE_SCHEMAS_FOLDER}
... mdsal=true
END
Check_Config_Data
[Arguments] ${expected} ${contains}=False
${data} = Get_Config_Data
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Check_Config_Data
[Arguments] ${expected} ${contains}=False
${data}= Get_Config_Data
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Check_Config_Data
[Arguments] ${expected} ${contains}=False
${data}= Get_Config_Data
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Count_Netconf_Connectors
[Arguments] ${node} ${expected} ${contains}=False
${url}= Builtin.Set_Variable ${REST_API}/network-topology:network-topology/topology=topology-netconf/node=${DEVICE_NAME}/yang-ext:mount?content=config
${data}= TemplatedRequests.Get_As_Xml_From_Uri ${url} session=${node}
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
[Documentation] Get device data from ${node}. Match against ${expected}, strictness given by ${contains}.
${url}= Builtin.Set_Variable ${REST_API}/network-topology:network-topology/topology=topology-netconf/node=${DEVICE_NAME}/yang-ext:mount?content=config
${data}= TemplatedRequests.Get_As_Xml_From_Uri ${url} session=${node}
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Populate_Schema_Directory_Over_Active_Connection
... CRUD).
${url}= Builtin.Set_Variable ${REST_API}/network-topology:network-topology/topology=topology-netconf/node=${DEVICE_NAME}/yang-ext:mount?content=config
${data}= TemplatedRequests.Get_As_Xml_From_Uri ${url} session=${session}
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Check_Owner_Reconfigured
... CRUD).
${url}= Builtin.Set_Variable ${REST_API}/network-topology:network-topology/topology=topology-netconf/node=${DEVICE_NAME}/yang-ext:mount?content=config
${data}= TemplatedRequests.Get_As_Xml_From_Uri ${url} session=${session}
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Check_Owner_Reconfigured
[Documentation] Check that the specified session sees the specified data in the test tool device.
${url}= Builtin.Set_Variable ${REST_API}/network-topology:network-topology/topology=topology-netconf/node=${DEVICE_NAME}/yang-ext:mount?content=config
${data}= TemplatedRequests.Get_As_Xml_From_Uri ${url} session=${node}
- BuiltIn.Run_Keyword_Unless ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
+ BuiltIn.Run_Keyword_If not ${contains} BuiltIn.Should_Be_Equal_As_Strings ${data} ${expected}
BuiltIn.Run_Keyword_If ${contains} BuiltIn.Should_Contain ${data} ${expected}
Wait_For_Netconf_Connector
[Documentation] Wait for the Netconf to go up for configurable time.
[Tags] critical
- BuiltIn.Run_Keyword_Unless ${netconf_is_ready} BuiltIn.Wait_Until_Keyword_Succeeds ${NETCONFREADY_WAIT} 1s Check_Netconf_Up_And_Running
+ BuiltIn.Run_Keyword_If not ${netconf_is_ready} BuiltIn.Wait_Until_Keyword_Succeeds ${NETCONFREADY_WAIT} 1s Check_Netconf_Up_And_Running
BuiltIn.Set_Suite_Variable ${netconf_is_ready} True
Wait_Even_Longer
Check_Whether_Netconf_Can_Pretty_Print
[Documentation] Make one request to netconf-connector and see if it works.
[Tags] critical
- BuiltIn.Run_Keyword_Unless ${netconf_is_ready} Fail Netconf is not ready so it can't pretty-print now.
+ BuiltIn.Run_Keyword_If not ${netconf_is_ready} Fail Netconf is not ready so it can't pretty-print now.
Check_Netconf_Up_And_Running ?odl-pretty-print=true
Wait_For_MDSAL