Using external javac compiler causes classes to not be instrumented with Clover

Symptoms

Running the following ANT command, example only:


ant clean with.clover compile

Builds the project successfully where classes are compiled as expected. However, the classes are not instrumented.

Cause

This is due to a compiler attribute is defined within the <javac/> task. For example:


<javac .......
compiler="<the_compiler>" .....
</javac>

However a compiler should not be specified here as outlined in the following documentation:

Resolution

Remove the compiler attribute from the <javac/> task and define the compiler using the clovercompile attribute within the <clover-setup> task.

Last modified on Nov 21, 2012

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.