title: Generate Code Coverage with JaCoCo and spring-boot-maven-plugin
body: <p>During integration tests I use spring-boot-maven-plugin to start my spring application:</p>
  
  <pre><code>&lt;plugin&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-maven-plugin&lt;/artifactId&gt;
      &lt;executions&gt;
           &lt;execution&gt;
               &lt;id&gt;start-spring-boot&lt;/id&gt;
               &lt;phase&gt;pre-integration-test&lt;/phase&gt;
               &lt;goals&gt;
                   &lt;goal&gt;start&lt;/goal&gt;
               &lt;/goals&gt;
           &lt;/execution&gt;
           &lt;execution&gt;
               &lt;id&gt;stop-spring-boot&lt;/id&gt;
               &lt;phase&gt;post-integration-test&lt;/phase&gt;
               &lt;goals&gt;
                   &lt;goal&gt;stop&lt;/goal&gt;
               &lt;/goals&gt;
           &lt;/execution&gt;
       &lt;/executions&gt;
  &lt;/plugin&gt;
  </code></pre>
  
  <p>Now I would like to add JaCoCo agent to the exection but adding it to the configuration as agent or jvmarguments didn't work. When starting I always see:</p>
  
  <pre><code>[INFO] --- spring-boot-maven-plugin:2.2.4.RELEASE:start (start-spring-boot) @ tosca-ui ---
  [INFO] Attaching agents: []
  </code></pre>
  
  <p>How can I use JaCoCo with spring-boot-maven-plugin?</p>