QAble Testlab Private Limited

What is TestNG.xml and How to use it?

What is TestNG

What is TestNG.xml ?

Method 1:

Method 2:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="Suite">
<test name="Test">
<classes>
<class name="testng.TestNGTestOne"/>
</classes>
</test> <!-- Test -->
</suite> <!-- Suite -->
<?xml version = "1.0" encoding = "UTF-8"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
<suite name = "Cycle1">
<test name = "Tutorialspoint">
<classes>
<class name = "Test1" />
<methods>
<exclude name= “Login.*”/>
</methods>
</classes>
</test>
</suite>

The testng.xml file has the numerous uses as listed below

How to use TestNG

QAble: A leading software testing company. We offer various software testing services to help you to achieve the best quality of your web & mobile application.