Hi All,

I have run into an issue while using Jacoco and wanted to know if someone here 
as an idea on what might be going on.

I have a set of 10 tests which are identified by the batchtest nested element 
under the junit target in my ant build script. As a result two batches of Junit 
tests are created at the time of execution with each batch contain 5 test.

While executing the Jacoco Coverage task I do a class dump to a particular 
folder.

When the first batch of test is executed the coverage target starts populating 
the class dump directory. 

However when the second batch starts once the first one completes the existing 
class dump directory is cleared and repopulated for the second batch. 

Hence I end up with a smaller code coverage percentage.

I deleted some of my tests to ensure that only one junit batch is created and 
verified that the coverage data captured is correct. So it looks like the issue 
happens when junit begins executing the second batch.

Any pointer or suggestions on this issue will be appreciated.

Thanks,
Joel

Ant build -

<jacoco:coverage 
destfile="${jacoco.reports.dir}/${ant.project.name}-jacoco.exec" 
classdumpdir="${jacoco.reports.dir}/${ant.project.name}">
 
 <junit fork="true" forkmode="once" timeout="1800000" printsummary="yes" 
failureproperty="test.failed" tempdir="${junit.tmp.dir}" dir="${junit.tmp.dir}">
  
  ...
  
  <batchtest todir="${junit.reports.dir}">
   <fileset dir="${src.test.java.dir}" includes="${test.files}"/>
  </batchtest>

 </junit>

</jacoco:coverage>

-- 
You received this message because you are subscribed to the Google Groups 
"JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to