Skip to main content
Spelling error fix in title
Link

How to call a keywrodkeyword recurvisely in robotframeworkRobot Framework

Source Link
Prasad_Joshi
  • 281
  • 3
  • 5
  • 18

How to call a keywrod recurvisely in robotframework

I have a keyword which checks, if a button value is Completed, once it is found, I want that keyword to stop and return the status. However the the button value Completed is not fixed to any time interval. I want to call the keyword recursively to check for value of button at every 3 minutes.

*** Test Case ***
   Navigate to menu    Home  Status
   #Something here to call the keywrod `Check run status` for every 3 
   minutes until ${passd} is true or 30 minutes are passed. 


***Keywrod***
 Check run status
${btnValue}  Get Text   //button[@id="btn_status"]  
${passed} =   Run Keyword And Return Status   Should be Equal   ${btnValue}   
Completed   
[Return]   ${passed}

How to iterate this with time interval & How can we achieve this with robotframework?