Checkout our demo site to practice selenium https://magento.softwaretestingboard.com/

0 like 0 dislike
319 views
by Contributing Tester (49 points)
Why do we need to run Selenium tests in parallel? What are its advantages?

5 Answers

1 like 0 dislike
by
Suppose we have to execute 100 automated test case and when we are executing all 100 cases sequentially - if it is taking approx. 10 minutes of times. By distributing these 100 automated test cases at different system(s) - we will be able to reduce total test exection time by 10 (original execution time) / number of systems we introduce for parellel running .e.g. we we introduce 5 systems for parellel execution - we may complete total test execution approximately in 2 minutes or so, which depends on various factors.
0 like 0 dislike
by Master (1.2k points)
To reduce your overall execution time.

Say, you have 50 tests where each test runs for 1 minute. If you run it one by one, it will take 50 min to complete the execution. But, if you run it in parallel with say 5 threads at a time, you can complete the same in 10 minutes. You will have to make sure that the tests you are running are independent of each other.
0 like 0 dislike
by Contributing Tester (79 points)
 

If you have many independent test cases that are taking lots of time in execution, in such cases to reduce overall Test execution time we use Selenium tests in parallel. This distributes the tests in different threads and reduces the overall execution time. This can be achieved via testng.xml configuration or via selenium grid also.

0 like 0 dislike
by
When you have many independent tests and you want to execute them in minimum possible time to decrease the overall automation suite execution time that time we use Selenium tests in parallel. This can be achieved via testng.xml  configuration or else via selenium Grid also.
0 like 0 dislike
by Contributing Tester (79 points)

Parallel test execution involves running a suite of automated tests in parallel as opposed to sequentially. You don’t execute your tests one by one. Rather, you take the entire batch and split it up amongst multiple servers so that each server can run a single test at a time. These techniques have some fantastic advantages to improve your overall software development life cycle.

Advantages of running parallel test:

  1. You can run multiple tests at once that are only limited by the hardware of your computer. It will decrease execution time because your longest run will be as long as your slowest test.

  2. If this is all you have available, then this is much better than running one test at a time sequentially.

The parallel test execution is different from sequential testing, where we test different modules or functionalities one after the other. Even in the case of testing applications on multiple browsers, tests are performed sequentially on various browsers. This approach of testing is very time-consuming.

Parallel testing helps to reduce execution time and efforts and results in faster time to delivery. It proves to be handy specifically in the case of automation, compatibility testing, localization, and internalization testing. In a scenario where we have two versions of software available, and we need to check its stability and compatibility, we can run the two versions simultaneously and find issues at a much faster rate.

You can use a platform like QAppAssure which allows you to test on-cloud and on-field devices, across 100+ device, make and models, Integrate with Jira, CI/CD tools, and also use Appium, Calabash, Espresso, UIAutomator, XCUITest. You can run unlimited parallel tests with the free trial pack. 


This site is for software testing professionals, where you can ask all your questions and get answers from 1300+ masters of the profession. Click here to submit yours now!

...