Generate test reports using the JUnit and ant that comes with eclipse
1. Click the project you want to test, right-click, select Export
2. On the pop-up page, click General, select Ant Buildfiles, click Next
3. On the next page, select the project you want to test, fill in the Ant profile name, Build.xml, test Report generated folder, such as reports, click Finish, you will generate an ant Build.xml file in the root directory.
4. Create a new folder in the root of the project, report (this folder will be built on its own and will not be generated automatically)
5. Right-click on the Build.xml file, in Run as, select the second, select the default target, the class to be tested, and Junitreport, click Run to generate JUnit's test report in the Reports folder.
Result: The order of execution is compiled first, then run Testadd, and the result is written to the report folder.
But according to their own experiments, this way can only run in eclipse, for example, when Jenkins calls the Build.xml file, only run the target under the default, this time will have to modify the configuration file, the Testadd and Junitreport Target is added in.
"Junit_ant" generates test reports using the eclipse's own Junit and Ant