I am running Selenium tests on Sauce through C#, Visual Studio, and NUnit.
For many of our applications, the time it takes to reach certain sections of an application can take quite a bit of time. For example, suppose it takes 30 seconds to a login and navigate to some page with a complex form.
I completely agree that each test should operate independently and mine do so. However, I may have 40 form validation test (e.g. TestFirstNameUpperLimit, TestFirstNameLowerLimit, TestFirstNameRequired, TestFirstNameSpecialCharacterLimitation, etc.). Once the form is reached, each test only takes 2-3 seconds at most to execute.
If I follow the Sauce guide, I would incur the login and navigation for each of those 40 tests. However, I can combine all of the validation logic into a single test and have a total execution time of around 1 minute as opposed to the 20 minute "separated tests." Unfortunately with this approach, I lose the individual test results and the ability to execute a single small test if debugging an issue (I shouldn't have to wait for 20 prior "mini-tests" to complete before reaching logic I'm testing).
This problem doesn't scale well (I have many applications with many many Selenium tests) and can't keep buying more VMs.
So in short, is there a way to resuse a current session and log multiple test results per session? For those familiar with NUnit or MSTest, I want to create a remote driver and do a login only once in FixtureSetup/ClassInitialize and then have logs for each test that occurrs after that.
Knowing who you are is very important. Life depends on how you define yourself. Be yourself; everyone else is already taken. — Oscar Wilde You might have seen come across quotes like: I am here fo...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events