Friday, July 6, 2018

How to execute test methods in parallel in TestNG?

Executing the test cases in parallel is one of the important automation feature. TestNG framework has this feature in built, we don't need to write separate code for this. Just with simple configuration in testng.xml file we can achieve the parallel execution at different levels.

We all know that the idea of having parallel execution is to reduce the execution time, with reduced execution time we can provide early feedback then we can save our efforts and money.

In this tutorial we will learn executing the test methods (test cases) in a java class file in parallel

Wednesday, July 4, 2018

How to enable or disable/ignore test methods in TestNG?

Sometimes we will be running into the situation where we need to disable/ignore some of the test cases or test methods from the execution because of various reasons like the test is failing due to known issue, the test data is not ready for the test and etc.

@Test annotation has many attributes, 'enabled' is the attribute used for disabling a test method. If we write @Test(enabled=false) for any test method in TestNG, then it will be ignored in the execution.

By default @Test() is enabled. @Test() is equivalent to @Test(enabled=true). Let us see an example on this to understand it better.

Tuesday, July 3, 2018

How to execute multiple test suites (testng.xml files) in TestNG?

We have seen In the previous post How to execute multiple test cases in TestNG? we discussed multiple ways of executing the test cases using a testng.xml (suite) file. In this post we will see executing multiple test suites in TestNG.

Generally in our projects we will be maintaining the test scripts in different test suites, say regressionSuite.xml, smokeSuite.xml.

DevOps 01: What is DevOps and How it benefits organizations?

DevOps is a culture in an organization, where the development team and operations team help each other by sharing information, process and t...