4

I'm writing the Selenium test cases for each screen to test the different scenarios. In our project for each build in Jenkins, its Selenium test cases (QA) also runs automatically.

My problem is even though it's automated, it's taking a lot of time to run. I have 380 test cases and it's taking 20-25 minutes. How can I reduce the time? Are there any other ways or techniques to follow?

hammar
  • 138,522
  • 17
  • 304
  • 385
srini
  • 6,719
  • 8
  • 32
  • 36

2 Answers2

0

In the 380 testcases you have , check if all the testcases are really required . If all the testcases are required , check if u are having any repeated validations and see if you can remove any one of them .

If you are using wait time in your testcases , see if you can reduce the wait times with out affecting the output of the testcases .

The best thing would be to split them in to seperate groups and run them in different machines using Grid . Or use TestNg/JUnit to run the testCases parallely .

In TestNg , in the testng.xml file , u can use the following to run them in parallel

<suite name="ParallelTests" verbose="5" parallel="methods" thread-count="10">

0

you can check for the Selenium grid option, which will help you to run the tests in parallel. http://selenium-grid.seleniumhq.org/

Jayendra
  • 52,349
  • 4
  • 80
  • 90
  • I have seen it and it is very useful.but how can i run my test suite in the remote server paralelly. – srini Sep 23 '11 at 15:02
  • Selenium grid can help run parallel tests on same machine or on different machines. You can check for the example on http://selenium-grid.seleniumhq.org/run_the_demo.html – Jayendra Sep 23 '11 at 15:14
  • How can i run the test cases for my project,where to configure and how to run – srini Sep 26 '11 at 09:02