Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Repeating a test in Selenium IDE

  • 13-09-2011 11:29am
    #1
    Registered Users, Registered Users 2 Posts: 156 ✭✭


    Hi there, I use Selenium IDE plug in got FF in work and I am self taught. Does anyone know if it is possible to "loop back" and repeat a test case and increase a variable by 1.

    For example I use it to register test accounts and at the moment if I want to create 20 new users I have to run it and then increase my test username eg from test101 to test 102 and run it again.

    is it possible to set it up to loop through 20 time each time increasing the username variable by +1 or something similar.

    Cheers,

    Mark.


Comments

  • Registered Users, Registered Users 2 Posts: 11,264 ✭✭✭✭jester77


    I don't think that is possible with the IDE, there are plugins that will do this but I've never used them.

    Easiest would be to implement the tests in PHP, Ruby, Python, C#, Java, etc and run them against a local standalone selenium server. I use Java with TestNG and it is very straight forward to get up and running. You could use a DataProvider for setting up your test users.


  • Registered Users, Registered Users 2 Posts: 1 xdolomite


    here is a simple loop in selenium IDE

    <tr>
    <td>store</td>
    <td>0</td>
    <td>index</td>
    </tr>
    <tr>
    <td>while</td>
    <td>index <20</td>
    <td></td>
    </tr>
    <tr>
    <td>storeEval</td>
    <td>index</td>
    <td>value</td>
    </tr>
    <tr>
    <td>echo</td>
    <td>${value}</td>
    <td></td>
    </tr><tr>
    <td>getEval</td>
    <td>index++;</td>
    <td></td>
    </tr>
    <tr>
    <td>endWhile</td>
    <td></td>
    <td></td>
    </tr>


Advertisement