jUnit: How to determine level of code coverage?

James Raitsev picture James Raitsev · Aug 12, 2010 · Viewed 53.1k times · Source

How can i determine what percentage of my methods (and code) are covered by jUnit tests? I am assuming there is a more sophisticated way then simply counting ... and 1 and 2 and ..

I specifically wonder how will such counting be handled when single method is covered by 'n' tests.

Answer

quamrana picture quamrana · Aug 12, 2010

I've used EclEmma very successfully to cover JUnit test runs. And its free.