Set priorities and depends on methods in testng

priorities testng

We can set priority to a test and also define upon which test ,this test dependes upon as below. ... Read More

Data providers in testng

data providers testng

We can provide a data provider to any of our tests in testng like this ``` @Test(dataProvider=" ... Read More

Common assert statements in testng

assert statements testng

``` Assert.assertEquals("Good","Goodx"); Assert.assertTrue(1>9 ,"Assertion failed"); Assert.asser ... Read More

Soft and hard assertions in Testng

soft hard assertions testng

In a testing method if we add some assert statement like this ``` @Test public void regClass( ... Read More

Running multiple testng tests in batch

xml testng

We can run mutiple testng suites by adding them to a suite.xml file like this ``` <suite name="M ... Read More

Custom Listeners in testng using iReporter

custom listener testng

We can make our custom reports using ireporter listener.Ireporter is an interface. We have to ... Read More

Running testng suites in maven project

testng maven

In pom.xml remove the junit dependency and add testng dependency instead. In this example we are usi ... Read More

Problems faced in testng

testng problems

1.Program stops if a assertion fails. If we want our program to continue even after assertion fails ... Read More

Include and exclude tags in xml

include exclude testng

Include and exclude is used to run a few testcases out of all test cases in a class as shown in exam ... Read More

Parameters to provide data to a testng test

parameters testng

DataProvider is used to provide data to a test case. Parameter can be used to provide a single va ... Read More