Introducing the testng XML file

The framework will be controlled by TestNG XML, which is an XML file with all the classes that have to be executed as part of the test run.

The TestNG.xml is shown in the following code and DriverScript will be the name of our main class: 

<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
<suite name="Suite1" verbose="1" >
<test name="FirstTest">
<classes>
<class name="packt.keywordframework.DriverScript"/>
</classes>
</test>
</suite>

Even though this will be the first class to be executed, it will not contain a Main method. We will see how we can trigger this class in a Chapter 7, The Command Pattern and Creating Components.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.17.167.114