Adding EMMA Report

Version 5 by Robin Shen
on Jun 18, 2008 21:39.


compared with
Version 6 by Robin Shen
on Jun 19, 2008 23:38.


Key
These lines were removed. This word was removed.
These lines were added. This word was added.

View page history


There are 1 changes. View first change.

 To add [EMMA|http://emma.sourceforge.net] report, only need two steps:
 # Generate EMMA *XML* report from [Ant|http://ant.apache.org] or [Maven|http://maven.apache.org] or any other build tools.
 # Publish EMMA report in the [configuration|Working with Configuration].
  
 h2. Generate EMMA Report
 QuickBuild will NOT generate [EMMA|http://emma.sourceforge.net] report automatically, so first make sure the EMMA report is produced by [ANT|http://ant.apache.org] or by any other build tools, the following example shows how to generate EMMA [code coverage|Glossary#code coverage] by [Ant EMMA task|http://emma.sourceforge.net/reference/ch02s02s02.html]:
  
 {code:xml|title=EMMA target in build.xml}
 <target name="emma_coverage">
  <emmajava enabled="${emma.enabled}" libclasspathref="emma.lib"
  filter="${emma.filter}" sourcepath="${src.dir}"
  classname="Main" classpathref="run.classpath">
  <arg value="someargvalue" />
  
  <xml outfile="reports/emma/coverage.xml" />
  </emmajava>
 </target>
 {code}
  
 The code snippet will generate the XML report for all the source code, a XML report: coverage.xml will be generated in 'reports/emma directory' directory which is relative to the [workspace|Glossary#workspace] directory.
  
 After adding generate the XML code coverage report for your source code, you can tell QuickBuild to add those results now.
  
 h2. Publish EMMA Report
  Just like all other [build reports|Publishing Build Reports], to add EMMA report is by [adding a publish step|Working With Step] in a [configuration|Working with Configuration]. When you add publish JUnit Report step, the following screen will be displayed:
  Just like all other [build reports|Publish Build Reports], to add EMMA report is by [adding a publish step|Working With Step] in a [configuration|Working with Configuration]. When you add publish JUnit Report step, the following screen will be displayed:
  
 !emma_step.png!
  
 In source files field, QuickBuild use Ant style file patterns to collect the reports, and the directory you specified is *relative* to the [workspace|Workspace Directory] directory.