All Versions
Clover 4.0 DocumentationClover 3.3 Documentation
Clover 3.2 Documentation
More...
This is the recommended method of installing Clover.
Adding Clover to your build is done by adding the following to your buildfile (e.g. build.xml):
<taskdef resource="cloverlib.xml" classpath="/path/to/clover.jar"/>
'/path/to' is the path to the 'clover.jar' file. Hence, a typical example of the 'classpath' parameter might be
classpath="../lib/clover.jar".
In some cases you may want to check if Clover is available before executing Clover-related targets. For example, you may need to ship the build file to others who may not have Clover installed. To check Clover's availability you can make use of the standard Ant <available> task:
<target name="-check.clover"> <available property="clover.installed" classname="com.cenqua.clover.CloverInstr" /> </target> <target name="guard.noclover" depends="-check.clover" unless="clover.installed"> <fail message="The target you are attempting to run requires Clover, which doesn't appear to be installed"/> </target> <target name="with.clover" depends="guard.noclover"> ...
ANT_OPTS to '-Dclover.debug=true'-debug and -verbose options<clover-env/> task to display Ant and Clover runtime information