1
votes

Using Selenium IDE 2.8.0 in conjunction with an XML file as my "datapool", how do I go about starting on a particular line/test case from the XML file? I can get it to run from beginning to end, no problem, but say something happens on the 3rd iteration and it fails. How would I start the test back up from the 3rd iteration instead of having to start back from the beginning?

An example would be say I'm searching the weather for a particular zip code and the "datapool" in xml would contain the folllowing:

Iteration     Zip Code
1             73102
2             73099
3             73064
4             73455
5             73869

Say the test failed on the 3rd iteration searching for 73064. When I start the test back up, I it to start from there and finish out with the other 2 remaining iterations.

Currently in RFT, I use a for loop to say which iteration of the datapool to start/end with, I am just having a hard time figuring it out with XML.

Thanks for any help offered.

1

1 Answers

0
votes

I figured this out a while ago and forgot to post my solution for anybody facing a similar situation in the future:

I stored a variable called "start", which is set to whichever row I want to start my test from and then was able to implement the following while loop: ${Iteration} == start

Right before the end of the endWhile, I did the following to iterate my test cases: javascript{storedVars.start++;}