Address issue for deprecated syntax
Change from :FOR to FOR/END to address a new WARNING in
the new robot version.
Change-Id: Id5d1259f3e8c928cc2425e7e6b2d0051358b99e1
Signed-off-by: Sushma M M <sushmm99@in.ibm.com>
diff --git a/redfish/dmtf_tools/Redfish_JsonSchema_ResponseValidator.robot b/redfish/dmtf_tools/Redfish_JsonSchema_ResponseValidator.robot
index 9fe7b6b..209228e 100644
--- a/redfish/dmtf_tools/Redfish_JsonSchema_ResponseValidator.robot
+++ b/redfish/dmtf_tools/Redfish_JsonSchema_ResponseValidator.robot
@@ -30,11 +30,12 @@
Set Test Variable ${test_run_status} ${True}
- :FOR ${url} IN @{url_list}
- \ ${output}= Run DMTF Tool ${rsv_dir_path} ${command_string} -i ${url}
- \ ${status}= Run Keyword And Return Status Redfish JsonSchema ResponseValidator Result ${output}
- \ Run Keyword If ${status} == ${False} Set Test Variable ${test_run_status} ${status}
- \ Save Logs For Debugging ${status} ${url}
+ FOR ${url} IN @{url_list}
+ ${output}= Run DMTF Tool ${rsv_dir_path} ${command_string} -i ${url}
+ ${status}= Run Keyword And Return Status Redfish JsonSchema ResponseValidator Result ${output}
+ Run Keyword If ${status} == ${False} Set Test Variable ${test_run_status} ${status}
+ Save Logs For Debugging ${status} ${url}
+ END
Run Keyword If ${test_run_status} == ${False}
... Fail Redfish-JsonSchema-ResponseValidator detected errors.
diff --git a/redfish/extended/test_bmc_dump.robot b/redfish/extended/test_bmc_dump.robot
index c659300..9d075a4 100644
--- a/redfish/extended/test_bmc_dump.robot
+++ b/redfish/extended/test_bmc_dump.robot
@@ -104,9 +104,10 @@
[Documentation] Create and delete BMC dump multiple times.
[Tags] Create_And_Delete_BMC_Dump_Multiple_Times
- :FOR ${INDEX} IN RANGE 1 5
- \ ${dump_id}= Create User Initiated Dump
- \ Delete BMC Dump ${dump_id}
+ FOR ${INDEX} IN 1 5
+ ${dump_id}= Create User Initiated Dump
+ Delete BMC Dump ${dump_id}
+ END
Delete All BMC Dumps And Verify
@@ -159,10 +160,11 @@
# Loop, creating a dump each iteration. Will either get dump_id or
# will get EMPTY when out of dump space.
- :FOR ${n} IN RANGE ${too_many_dumps}
- \ ${dump_id}= Create User Initiated Dump check_out_of_space=${True}
- \ Exit For Loop If '${dump_id}' == '${EMPTY}'
- \ Check Existence Of BMC Dump File ${dump_id}
+ FOR ${n} IN RANGE 0 ${too_many_dumps}
+ ${dump_id}= Create User Initiated Dump check_out_of_space=${True}
+ Exit For Loop If '${dump_id}' == '${EMPTY}'
+ Check Existence Of BMC Dump File ${dump_id}
+ END
Run Keyword If '${dump_id}' != '${EMPTY}' Fail
... msg=Did not run out of dump space as expected.
diff --git a/redfish/extended/test_remote_logging.robot b/redfish/extended/test_remote_logging.robot
index a62fc0e..eafc645 100644
--- a/redfish/extended/test_remote_logging.robot
+++ b/redfish/extended/test_remote_logging.robot
@@ -300,10 +300,11 @@
@{lines}= Split To Lines ${bmc_journald}
- :FOR ${line} IN @{lines}
- \ Log To Console \n ${line}
- \ Should Contain ${remote_journald} ${line}
- ... mgs=${line} line doesn't contain in ${remote_journald}.
+ FOR ${line} IN @{lines}
+ Log To Console \n ${line}
+ Should Contain ${remote_journald} ${line}
+ ... mgs=${line} line doesn't contain in ${remote_journald}.
+ END
*** Keywords ***
diff --git a/redfish/extended/test_software_manager.robot b/redfish/extended/test_software_manager.robot
index de5e570..b523f12 100755
--- a/redfish/extended/test_software_manager.robot
+++ b/redfish/extended/test_software_manager.robot
@@ -23,11 +23,11 @@
${object_uris}= Read Properties ${SOFTWARE_VERSION_URI}list
- :FOR ${uri} IN @{object_uris}
- \ ${object}= Read Properties ${uri}
- \ Continue For Loop If not 'Purpose' in ${object}
- \ Should Contain Any &{object}[Purpose] ${VERSION_PURPOSE_HOST}
- ... ${VERSION_PURPOSE_BMC}
+ FOR ${uri} IN @{object_uris}
+ ${object}= Read Properties ${uri}
+ Continue For Loop If not 'Purpose' in ${object}
+ Should Contain Any &{object}[Purpose] ${VERSION_PURPOSE_HOST} ${VERSION_PURPOSE_BMC}
+ END
BMC Software Hex ID
diff --git a/redfish/systems/test_systems_inventory.robot b/redfish/systems/test_systems_inventory.robot
index 606cf09..915448c 100755
--- a/redfish/systems/test_systems_inventory.robot
+++ b/redfish/systems/test_systems_inventory.robot
@@ -39,7 +39,7 @@
# Get the number of cores.
${total_num_cores}= Set Variable ${0}
- :FOR ${cpu} IN @{cpus_ok}
+ FOR ${cpu} IN @{cpus_ok}
${cores}= Get CPU TotalCores ${cpu}
${total_num_cores}= Evaluate $total_num_cores + ${cores}
END
@@ -99,7 +99,7 @@
# Count the power supplies that are Enabled or StandbyOffline.
${total_num_supplies}= Set Variable ${0}
- :FOR ${power_supply} IN @{power_supplies_ok}
+ FOR ${power_supply} IN @{power_supplies_ok}
# Example of power_supply:
# power_supply = {'@odata.id': '/redfish/v1/Chassis/chassis/Power#/PowerSupplies/0',
# 'Manufacturer': '', 'MemberId': 'powersupply0', 'Model': '2100', 'Name':
@@ -186,7 +186,7 @@
# Select only GPUs with Health = "OK".
${gpus_ok}= Filter Struct ${gpu_info} [('Health', 'OK')]
- :FOR ${gpu} IN @{gpus_ok}
+ FOR ${gpu} IN @{gpus_ok}
${status}= Redfish.Get Attribute ${gpu} Status
${state}= Set Variable ${status['State']}
${good_state}= Evaluate