JaCoCo, Maven and NetBeans 8 integration

May 22, 2014 by Michael

I was looking for a nice solution to measure the code coverage in my Spring Boot biking project.

It should support Java 8, Maven and for added bonus, my IDE.

I ended up using JaCoCo respectively the Maven plugin.

If you expect a lengthier post, i must disappoint you. All that was need to turn this:


into this


and also having a nice report like this (right click in NetBeans 8 on the project and choose “Code Coverage > Show Report…”)


was the following plugin declaration in maven:

		<!-- Application starter -->
		<!-- Configuration -->
			<!--  implmentation is needed only for Maven 2  -->
			<rule implementation="org.jacoco.maven.RuleConfiguration">
				<limit implementation="org.jacoco.report.check.Limit">
				<!--  implmentation is needed only for Maven 2  -->
				<limit implementation="org.jacoco.report.check.Limit">

That’s it. NetBeans 8 recognizes JaCoCo immediately and everything works (except for my project not reaching my self set limits). No additional installs, no weird maven problems. Awesome.

Also i had no problems with JaCoCo and Java 8 features of any kind.


  1. Merlin Thomas wrote:

    Thanks for the post. Did exactly what I needed real quick.

    Posted on December 16, 2014 at 4:32 PM | Permalink
  2. Henrik wrote:

    Brilliant. Got it working in 2 minutes. Thank you!

    Posted on June 1, 2015 at 3:21 PM | Permalink
  3. Michael wrote:

    You’re welcome!

    Posted on June 8, 2015 at 9:42 AM | Permalink
Post a Comment

Your email is never published nor shared. Required fields are marked *