O'Reilly logo

Selenium Testing Tools Cookbook - Second Edition by Unmesh Gundecha

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating and executing the Selenium script in parallel with TestNG

Now that we have our Selenium Grid Hub and nodes ready and configured from previous recipes, it's time to run tests in parallel with this distributed environment.

To run tests in parallel, we need a test framework that supports distributing tests on these nodes. We will use TestNG to run tests in parallel for Selenium tests developed with Java bindings.

TestNG (http://testng.org) is another popular unit testing frameworks used by the Java community after JUnit. TestNG allows us to create tests that can be executed in parallel. We can set up a group of tests or test suites and have parameters configured to run these tests in parallel. It uses a multithreading model to run tests in ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required