Does anybody know about an Eclipse plug-in to analyze code coverage for TestNG unit tests?
Go to Windows Menu bar > Show View > Other > Type coverage and open it. Click on Coverage. To clear highlightings, click on X or XX icon as per convenience.
If it is the first time, you need to install eclemma from marketplace, after installation it will restart. Below is the path to find the coverage. Window >> Show view >> Other >> Type coverage, click on the coverage. When you do coverage as junit , you can able to see the code coverage.
EclEmma can be run on TestNG test suites. You can also run a group of test or a given TestNG class with it. It requires the TestNg plug-in
On EclEmma plugin, choose "coverage configuration..." and select the TestNG tab.
Yes EclEmma is the best one. You can also try maven based cobertura which is also good enough.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With