From 9f43fd9fabb460318c0950d59cfc032ec0e42fda Mon Sep 17 00:00:00 2001 From: Sangwook Ha Date: Sat, 2 Apr 2022 16:01:22 -0700 Subject: [PATCH] Replace 'Run Keyword Unless' Builtin keyword 'Run Keyword Unless' has been deprecated since v5.0: https://github.com/robotframework/robotframework/issues/4174 Replace it with 'Run Keyword If'. Change-Id: Id721d6ebd8e1304d23242d1700b04087ea86217d Signed-off-by: Sangwook Ha --- csit/libraries/ClusterManagement.robot | 2 +- csit/libraries/ClusterOpenFlow.robot | 6 +++--- csit/libraries/ExaBgpLib.robot | 2 +- csit/libraries/FlowLib.robot | 6 +++--- csit/libraries/GUIKeywords.robot | 6 +++--- csit/libraries/Genius.robot | 2 +- csit/libraries/GoBgpLib.robot | 2 +- csit/libraries/KarafKeywords.robot | 2 +- csit/libraries/TemplatedRequests.robot | 6 +++--- csit/libraries/controller/CsCommon.robot | 2 +- csit/suites/bgpcep/bgpclustering/PrefixcountKeywords.robot | 2 +- .../controller/singleton_service/global_rpc_freeze.robot | 2 +- .../controller/singleton_service/global_rpc_isolate.robot | 2 +- .../controller/singleton_service/global_rpc_kill.robot | 2 +- .../groupbasedpolicy/GBP/3-node/gbp1/002_wait_flows.robot | 6 +++--- .../GBP/3-node/gbp2-multitenant/002_wait_flows.robot | 6 +++--- .../groupbasedpolicy/GBPSXP/ep_provider_renderer_part.robot | 2 +- csit/suites/netconf/CRUD-ACTION/CRUD-ACTION.robot | 2 +- csit/suites/netconf/CRUD/CRUD-RPC.robot | 2 +- csit/suites/netconf/CRUD/CRUD.robot | 2 +- csit/suites/netconf/clustering/CRUD.robot | 2 +- csit/suites/netconf/clustering/bug8086.robot | 2 +- .../suites/netconf/clustering/entity-isolation-rejoin.robot | 2 +- csit/suites/netconf/clustering/entity.robot | 2 +- csit/suites/netconf/clustering/outages.robot | 2 +- csit/suites/netconf/ready/netconfready.robot | 4 ++-- 26 files changed, 39 insertions(+), 39 deletions(-) diff --git a/csit/libraries/ClusterManagement.robot b/csit/libraries/ClusterManagement.robot index c58fb4c80c..4982cbb4a6 100644 --- a/csit/libraries/ClusterManagement.robot +++ b/csit/libraries/ClusterManagement.robot @@ -183,7 +183,7 @@ Verify_Shard_Leader_Elected ... 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 diff --git a/csit/libraries/ClusterOpenFlow.robot b/csit/libraries/ClusterOpenFlow.robot index 5c1176c319..d1dea64f2a 100644 --- a/csit/libraries/ClusterOpenFlow.robot +++ b/csit/libraries/ClusterOpenFlow.robot @@ -169,9 +169,9 @@ Check Linear Topology On Member 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 diff --git a/csit/libraries/ExaBgpLib.robot b/csit/libraries/ExaBgpLib.robot index ef110c9ee5..15167ddde6 100644 --- a/csit/libraries/ExaBgpLib.robot +++ b/csit/libraries/ExaBgpLib.robot @@ -57,7 +57,7 @@ Start_ExaBgp_And_Verify_Connected 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 diff --git a/csit/libraries/FlowLib.robot b/csit/libraries/FlowLib.robot index 8e5f7e5cd2..70b6e02701 100644 --- a/csit/libraries/FlowLib.robot +++ b/csit/libraries/FlowLib.robot @@ -76,9 +76,9 @@ Check Linear Topology 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 diff --git a/csit/libraries/GUIKeywords.robot b/csit/libraries/GUIKeywords.robot index 8b36382113..ab33e8346d 100644 --- a/csit/libraries/GUIKeywords.robot +++ b/csit/libraries/GUIKeywords.robot @@ -93,7 +93,7 @@ Open Virtual Display 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. @@ -110,7 +110,7 @@ Launch DLUX ... 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 @@ -163,7 +163,7 @@ Navigate To URL [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} diff --git a/csit/libraries/Genius.robot b/csit/libraries/Genius.robot index 6cc208d06a..7e499e6c33 100644 --- a/csit/libraries/Genius.robot +++ b/csit/libraries/Genius.robot @@ -236,7 +236,7 @@ Get Tunnel 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} diff --git a/csit/libraries/GoBgpLib.robot b/csit/libraries/GoBgpLib.robot index 0b871da7ed..402d078394 100644 --- a/csit/libraries/GoBgpLib.robot +++ b/csit/libraries/GoBgpLib.robot @@ -54,7 +54,7 @@ Start_GoBgp_And_Verify_Connected 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 diff --git a/csit/libraries/KarafKeywords.robot b/csit/libraries/KarafKeywords.robot index 2480149297..6e935f5eb9 100644 --- a/csit/libraries/KarafKeywords.robot +++ b/csit/libraries/KarafKeywords.robot @@ -222,7 +222,7 @@ Log_Message_To_Controller_Karaf ${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 diff --git a/csit/libraries/TemplatedRequests.robot b/csit/libraries/TemplatedRequests.robot index 99a19b2332..158b57f66c 100644 --- a/csit/libraries/TemplatedRequests.robot +++ b/csit/libraries/TemplatedRequests.robot @@ -386,7 +386,7 @@ Get_From_Uri ${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} @@ -406,7 +406,7 @@ Put_To_Uri ... 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} @@ -426,7 +426,7 @@ Post_To_Uri ... 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} diff --git a/csit/libraries/controller/CsCommon.robot b/csit/libraries/controller/CsCommon.robot index 7baed66c48..1b3fb3ccbf 100644 --- a/csit/libraries/controller/CsCommon.robot +++ b/csit/libraries/controller/CsCommon.robot @@ -102,7 +102,7 @@ Verify_Singleton_Constant_During_Isolation [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 diff --git a/csit/suites/bgpcep/bgpclustering/PrefixcountKeywords.robot b/csit/suites/bgpcep/bgpclustering/PrefixcountKeywords.robot index 5833d0c76b..c7486d9022 100644 --- a/csit/suites/bgpcep/bgpclustering/PrefixcountKeywords.robot +++ b/csit/suites/bgpcep/bgpclustering/PrefixcountKeywords.robot @@ -107,7 +107,7 @@ Start_Bgp_Peer_And_Verify_Connected 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 diff --git a/csit/suites/controller/singleton_service/global_rpc_freeze.robot b/csit/suites/controller/singleton_service/global_rpc_freeze.robot index fab66354d0..a093d01790 100644 --- a/csit/suites/controller/singleton_service/global_rpc_freeze.robot +++ b/csit/suites/controller/singleton_service/global_rpc_freeze.robot @@ -101,7 +101,7 @@ Verify_Owner_Elected [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} diff --git a/csit/suites/controller/singleton_service/global_rpc_isolate.robot b/csit/suites/controller/singleton_service/global_rpc_isolate.robot index 9cde934609..83a5b85936 100644 --- a/csit/suites/controller/singleton_service/global_rpc_isolate.robot +++ b/csit/suites/controller/singleton_service/global_rpc_isolate.robot @@ -109,7 +109,7 @@ Verify_Owner_Elected [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} diff --git a/csit/suites/controller/singleton_service/global_rpc_kill.robot b/csit/suites/controller/singleton_service/global_rpc_kill.robot index 764fb6c2a8..04f83b43cf 100644 --- a/csit/suites/controller/singleton_service/global_rpc_kill.robot +++ b/csit/suites/controller/singleton_service/global_rpc_kill.robot @@ -104,7 +104,7 @@ Verify_Owner_Elected [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} diff --git a/csit/suites/groupbasedpolicy/GBP/3-node/gbp1/002_wait_flows.robot b/csit/suites/groupbasedpolicy/GBP/3-node/gbp1/002_wait_flows.robot index 292b539399..5a0d48a3aa 100644 --- a/csit/suites/groupbasedpolicy/GBP/3-node/gbp1/002_wait_flows.robot +++ b/csit/suites/groupbasedpolicy/GBP/3-node/gbp1/002_wait_flows.robot @@ -14,8 +14,8 @@ ${timeout} 10s 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! diff --git a/csit/suites/groupbasedpolicy/GBP/3-node/gbp2-multitenant/002_wait_flows.robot b/csit/suites/groupbasedpolicy/GBP/3-node/gbp2-multitenant/002_wait_flows.robot index 37019c603f..e715817c06 100644 --- a/csit/suites/groupbasedpolicy/GBP/3-node/gbp2-multitenant/002_wait_flows.robot +++ b/csit/suites/groupbasedpolicy/GBP/3-node/gbp2-multitenant/002_wait_flows.robot @@ -14,8 +14,8 @@ ${timeout} 10s 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! diff --git a/csit/suites/groupbasedpolicy/GBPSXP/ep_provider_renderer_part.robot b/csit/suites/groupbasedpolicy/GBPSXP/ep_provider_renderer_part.robot index da8ef1c514..91bb35b6be 100644 --- a/csit/suites/groupbasedpolicy/GBPSXP/ep_provider_renderer_part.robot +++ b/csit/suites/groupbasedpolicy/GBPSXP/ep_provider_renderer_part.robot @@ -70,7 +70,7 @@ Setup_Http_And_Netconf 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 diff --git a/csit/suites/netconf/CRUD-ACTION/CRUD-ACTION.robot b/csit/suites/netconf/CRUD-ACTION/CRUD-ACTION.robot index 308e284e00..7685e922b6 100644 --- a/csit/suites/netconf/CRUD-ACTION/CRUD-ACTION.robot +++ b/csit/suites/netconf/CRUD-ACTION/CRUD-ACTION.robot @@ -127,5 +127,5 @@ Get_Config_Data 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} diff --git a/csit/suites/netconf/CRUD/CRUD-RPC.robot b/csit/suites/netconf/CRUD/CRUD-RPC.robot index 1830a0a95d..301488e43d 100644 --- a/csit/suites/netconf/CRUD/CRUD-RPC.robot +++ b/csit/suites/netconf/CRUD/CRUD-RPC.robot @@ -249,5 +249,5 @@ Get_Config_Data 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} diff --git a/csit/suites/netconf/CRUD/CRUD.robot b/csit/suites/netconf/CRUD/CRUD.robot index 4551ec1005..cfce999773 100644 --- a/csit/suites/netconf/CRUD/CRUD.robot +++ b/csit/suites/netconf/CRUD/CRUD.robot @@ -241,7 +241,7 @@ Get_Config_Data 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 diff --git a/csit/suites/netconf/clustering/CRUD.robot b/csit/suites/netconf/clustering/CRUD.robot index 5cf95e0d15..3ba359058a 100644 --- a/csit/suites/netconf/clustering/CRUD.robot +++ b/csit/suites/netconf/clustering/CRUD.robot @@ -211,5 +211,5 @@ Check_Config_Data [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} diff --git a/csit/suites/netconf/clustering/bug8086.robot b/csit/suites/netconf/clustering/bug8086.robot index 6f3ccc6af5..50285e84d8 100644 --- a/csit/suites/netconf/clustering/bug8086.robot +++ b/csit/suites/netconf/clustering/bug8086.robot @@ -202,7 +202,7 @@ Check_Config_Data [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 diff --git a/csit/suites/netconf/clustering/entity-isolation-rejoin.robot b/csit/suites/netconf/clustering/entity-isolation-rejoin.robot index 5f84bc7a98..db4265aeb5 100644 --- a/csit/suites/netconf/clustering/entity-isolation-rejoin.robot +++ b/csit/suites/netconf/clustering/entity-isolation-rejoin.robot @@ -194,7 +194,7 @@ Check_Config_Data ... 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 diff --git a/csit/suites/netconf/clustering/entity.robot b/csit/suites/netconf/clustering/entity.robot index e101345d7b..71fdb0b4a7 100644 --- a/csit/suites/netconf/clustering/entity.robot +++ b/csit/suites/netconf/clustering/entity.robot @@ -198,7 +198,7 @@ Check_Config_Data ... 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 diff --git a/csit/suites/netconf/clustering/outages.robot b/csit/suites/netconf/clustering/outages.robot index 9c6a000d42..21315dbd8e 100644 --- a/csit/suites/netconf/clustering/outages.robot +++ b/csit/suites/netconf/clustering/outages.robot @@ -228,5 +228,5 @@ Check_Config_Data [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} diff --git a/csit/suites/netconf/ready/netconfready.robot b/csit/suites/netconf/ready/netconfready.robot index 15bdeebe11..89565b77f3 100644 --- a/csit/suites/netconf/ready/netconfready.robot +++ b/csit/suites/netconf/ready/netconfready.robot @@ -92,7 +92,7 @@ Check_Whether_Netconf_Connector_Is_Up_And_Running 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 @@ -119,7 +119,7 @@ Check_For_Bug_5014 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 -- 2.36.6