Codecoverage for Application under test

30 views
Skip to first unread message

dharm...@gmail.com

unread,
Mar 26, 2015, 1:45:27 PM3/26/15
to jac...@googlegroups.com
Hi,
my java based application is deployed and used as a web service where i use the browser to login to the application and test it.
I have tests that are running in eclipse. I want to test the code coverage of the application under test as i run my tests in eclipse.
From the initial understanding, i felt that JaCoCo and EclEmma can provide me the code coverage of the "tests" but not for the "application under test".
Please let me know if there is a way i can use these tools to get a code coverage report for the web based application under test

thanks

Marc R. Hoffmann

unread,
Mar 27, 2015, 12:55:40 AM3/27/15
to jac...@googlegroups.com
Hi,

in this case you need to collect execution information from the server
where your web service is deployed. If you can't start your server
locally from Eclipse with EclEmma you can configure the JaCoCo agent
manually to collect coverage data:

http://www.eclemma.org/jacoco/trunk/doc/agent.html

If (and only if!) the web services is deployed based on the classfiles
within your Eclipse IDE you an directly import execution data from the
agent into Eclipse:

http://www.eclemma.org/userdoc/importexport.html

Otherwise you can create coverage reports with the JaCoCo Ant task or
Maven goal:

http://www.eclemma.org/jacoco/trunk/doc/ant.html#report
http://www.eclemma.org/jacoco/trunk/doc/report-mojo.html

Regards,
-marc
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages