If you installed the Code Quality Extension for Continuous
Integration (CQECI) into a Rational Team Concert™ build
system, then add a new build definition in Rational Team Concert for your
build that generates code coverage statistics.
Before you begin
Start the Rational
Team Concert client. In the Team Artifacts view, open your project
and create an XML file (for example, build.xml) for your Ant build
script.
Procedure
- In the Team Artifacts view, expand the project folder.
- Right-click Builds; then click New
Build Definition.
- In the New Build Definition wizard, on the New Build Definition
page, accept the defaults and click Next.
- On the General Information page, in the Available build
templates pane, select Ant - Jazz Build Engine and
click Next.
- If you use Rational
Team Concert source control, on the Pre-build page, select Jazz
Source Control.
- Click Finish. The
Build Definition editor opens.
- In the Supporting Build Engines section of the Build Definition
editor, select the build engines to use for your new build definition,
or click Create Engine to create a new build
engine.
- Change to the Jazz™ Source
Control tab in the build definition editor. In the Build
Workspace section, click Select to
select the repository workspace that contains the code to check out
during the build.
- In the Build Definition editor, in the Load Options pane,
in the Load directory field, type the path
to the directory on the build machine where you want to load the workspace
files. Optionally, check Delete directory before
loading to clear the directory every time the build runs.
- Change to the Ant tab in the build
definition editor and complete the following steps:
- In the Build file field, type
the Ant build file to run. The path is relative to the directory used
to save the code checked out from the repository workspace, and so
it has the form Load directory/Project
name/build file name.xml For example, if your Project name is
Sample, the Load directory is name fetched, and
the build file name is build.xml, then you would
enter fetched/Sample/build.xml in the Build
file field.
- In the Ant Configuration section,
select Include the Jazz build toolkit tasks on the Ant
library path.
- In the Ant arguments field, enter -lib RTC_build_system_install_directory\codecoverage\plugins,
where RTC_build_system_install_directory is the
installation directory of the Build Toolkit. In most of
cases, you need to specify the JDT compiler and JDT core in the Ant
arguments field, for example, enter -lib RTC_build_system_install_directory\codecoverage\plugins\jdtCompilerAdapter.jar and -lib RTC_build_system_install_directory\codecoverage\plugins\org.eclipse.jdt.core_xxx.jar,
What to do next
Create a build.xml file to generate code coverage statistics.