Hi All,
I am working with Selenium in order to create load balancing tests on a web server. The website has a username/password and in order to work with this I have a csv file filled with username password combinations.
The issue is I am using the random function in Javascript to select a row from the csv file and populate the login functionality or registration details.
var csv = browserMob.getCSV("pickStickEmails.csv");
var row = csv.random();
var Email = row.get("email");
var Password = row.get("password");
selenium.type("ctl00_StandardMainBodyPlaceHolder_ctl00_TextBoxEmail", Email);
selenium.type("ctl00_StandardMainBodyPlaceHolder_ctl00_TextBoxEmailConfirm", Email);
selenium.type("ctl00_StandardMainBodyPlaceHolder_ctl00_TextBoxPassword", Password);
selenium.type("ctl00_StandardMainBodyPlaceHolder_ctl00_TextBoxPasswordConfirm", Password);
This obviously brings up issues when registering if the same record is selected twice during a scheduled run. Obviously with the login situation if a record isn't selected when registering and is then selected on a test that requires an existing account the test fails due to it not existing.
My question is, is it possible to somehow get browserMob to iterate through the records one at a time? Obviously when browserMob begins a load test it ramps up to lets say 10 users using the website at one time each running the script I assume?
I did write the test using Selenium-RC in C# with NUnit and read the csv file into a List and then iterated through the list. Obviously this runs each user after another and doesn't simulate multiple users being on the site at one time.
Any advice on this would be greatly appreciated.
Thanks,
Jon