GUI robot test code with latest directives
Changes:
- Run Keyword If is deprecated since Robot
Framework version 5.*, use 'IF' instead
- Remove the keyword from teardown and add
check in the keyword to re-run GUI if
test failed.
Tested:
- Tested with dry-run option changes
Change-Id: Ie1b0957470ac4a33c846aa153a0c776fdba34db5
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/gui/lib/gui_resource.robot b/gui/lib/gui_resource.robot
index 5c13da7..96b9f13 100644
--- a/gui/lib/gui_resource.robot
+++ b/gui/lib/gui_resource.robot
@@ -198,8 +198,9 @@
Click Button ${xpath_add_dns_ip_address_button}
Input Text ${xpath_input_static_dns} ${dns_server}
Click Button ${xpath_add_button}
- Run keyword if '${expected_status}' != 'Valid format'
- ... Run keywords Page Should Contain ${expected_status} AND Return From Keyword
+ IF '${expected_status}' != 'Valid format'
+ Page Should Contain ${expected_status} AND Return From Keyword
+ END
Wait Until Page Contains Element ${xpath_add_dns_ip_address_button} timeout=10sec
Wait Until Page Contains ${dns_server} timeout=40sec