HOW TO USE WHILE LOOP IN SELENIUM IDE USING FLOW CONTROL EXTENSION?





Run the below script in selenium IDE:

Command
Target
Value
storing a search key as variable


store
1
x
test script started from here


while
(${x}<10)

echo
${x}

open
/
focus
//input[@id='gbqfq']

type
//input[@id='gbqfq']
${x}
focus
//button[@id='gbqfb']

clickAndWait
//button[@id='gbqfb']

storeEval
storedVars['x'] = ${x}+1

endWhile


test script ended from here


storeEval
alert('Test executed successfully!!')


* Base URL:
http://www.google.co.in/






In the above script we are using the flow control to perform a while loop operation for increasing a number.


Read more about WHAT IS FLOW CONTROL?

Read more about HOW TO INSTALL FLOW CONTROL?





Post a Comment

0 Comments