

(or Run / Debug.) menu and create a new TestNG

More testng.xml files, you can create a TestNG Launch Configuration. Once you have created classes that contain TestNG annotations and/or one or The plug-in will make a guess about the best location where this file should be created (for example, if you are using Maven, the default location will be under src/test/java). The next page lets you specify where that file will be created, whether it should contain default implementation for some configuration methods, if you'd like a data provider and finally, if a testng.xml file should be generated. Each method you select on this page will be included in the new TestNG class with a default implementation that throws an exception, so you remember to implement it. If you currently have a Java file open in the editor or if you have a Java file selected in the Navigator, the first page of the wizard will show you a list of all the public methods of that class and it will give you the option to select the ones you want to test. To create a new TestNG class, select the menu File / New / TestNG: NOTE: since TestNG Eclipse Plugin 6.9.8, the minimum required TestNG version is 6.5.1 2 - Creating a TestNG class and you should see the TestNG view listed in the Java category. Once done, restart Eclipse and select the menu Window / Show View / Other. It's recommended to install it if your Java project(s) are managed by Maven. NOTE: since TestNG Eclipse Plugin 6.9.10, there is a new optional plug-in for M2E (Maven Eclipse Plugin) integration. Table of Contents 1 - Installationģ.5 - Specifying listeners and other settingsįollow the instructions to install the plug-in. It has its own project repository called testng-eclipse. The TestNG Eclipse plug-in allows you to run your TestNG tests from EclipseĪnd easily monitor their execution and their output.
