Clover 2.0 Upgrade Guide for Ant


Added by Rosie Jameson, last edited by Rosie Jameson on Oct 03, 2007

Labels:

Enter labels to add to this page:
Wait Image 
Looking for a label? Just start typing.
Clover 2.0 Beta Documentation

Index

Clover 2.0 Upgrade Guide for Ant

We've taken care to make the upgrade to Clover 2.0 straightforward.

If you are using Clover 1.x with Ant, follow these simple steps to upgrade to Clover 2.0:

1. Replace 1.x clover.jar with the 2.x clover.jar
You can do this by simply copying the new jar over the top of the old one.

2. Obtain and install a Clover 2.x license
Output similar to the following will appear when Clover is run:

[clover] Clover Version 2.X, built on ...
 [clover] Loaded from: c:/ant/lib/clover.jar

3. Configure the Test Results Directory (optional)
You can now optionally configure the Clover report tasks to include test result information in the generated report. If you are using the <clover-report> task, add a <testresults/> fileset element. If you are using the <clover-html-report> task, provide a testresultsdir attribute. This enables Clover 2 to display your Test Results and your Test Coverage in the same report. Please read Unit Test Results and Per-Test Coverage for more information.

4. Delete any existing Coverage database.
The Clover database is created at the location specified in the initstring attribute of <clover-setup>.

Note
In Clover 2, the initstring parameter is now optional. We recommend leaving it unspecified unless you want to explicitly control where Clover writes its database file.

Please also read the Best practices for Ant integration.