Hello,

I am still a bit confused by the way JaCoCo detects which class files
correspond to which source files.
Given I have a multi-module reactor project where testA has moduleA as
dependency
root/
      moduleA
      testA
When I execute the tests in testA all classes from moduleA show up in
jacoco.exec as well as the classes of maven-surefire-plugin and junit,
e.g.

Now when I add the source folder from moduleA via
buildhelper-maven-plugin to the sources of testA I have two different
outcomes:
- When I attach the sources in the standard phase (generate-sources)
as one would expect the maven-compiler-plugin compiles the sources of
moduleA again, class files are beneath testA/target/classes and
coverage for all classes is reported.
- When I attach the sources in another phase (say prepare-package) the
maven-compiler-plugin does not compile the sources again, however the
report now is completely empty.

The class files of moduleA are included during the reactor run by
adding moduleA/target/classes to the classpath of testA, the sources
of moduleA are not modified, nonetheless JaCoCo is not able to deduce
that the class files are valid.

Regards Mirko
--
http://illegalstateexception.blogspot.com/
https://github.com/mfriedenhagen/ (http://osrc.dfm.io/mfriedenhagen)
https://bitbucket.org/mfriedenhagen/

-- 
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