Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,359,884
Community Members
 
Community Events
168
Community Groups

Sauce Labs: How to log multiple test results in a single test?

Edited

Hello,

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. 

 

 

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Off-topic

Don't F&*% the planet.

Over the weekend, Atlassian ran a New York Times ad calling on business leaders to join us in committing to a net zero future through the Science-Based Targets Initiative. As part of our gl...

1,641 views 10 55
Read article

Atlassian Community Events