changes.
| Since QuickBuild 5.1.22, you can generate and publish [Clover|https://www.atlassian.com/software/clover/overview] XML report by: |
| # Generate Cobertura *XML* report from [Ant|http://ant.apache.org] or [Maven|http://maven.apache.org] or any other build tool. |
| # Add Cobertura publish step by choosing _Publish -> Cobertura Report_ from step menu. |
| |
| | {note:title=Note} |
| The clover should be version 3.2.2 or higher. |
| {note} |
| |
| h2. Generate Clover Report |
| |
| QuickBuild will NOT generate [Clover|https://www.atlassian.com/software/clover/overview] report automatically, so first make sure the [Clover|https://www.atlassian.com/software/clover/overview] report is produced by [ANT|http://ant.apache.org] or by any other build tool. The following example shows how to generate Cobertura test results with [Ant|https://confluence.atlassian.com/display/CLOVER/Clover-for-Ant] or [Maven|https://confluence.atlassian.com/display/CLOVER/Clover-for-Maven+2+and+3] |
| {code:xml|title=Clover coverage report target in build.xml} |
| <target name="clover.current" depends="test.run"> |
| <clover-report> |
| <current outfile="${clover.report.dir}/clover.xml" title="Clover Demo" charset="UTF-8" > |
| <format type="xml"/> |
| <columns> |
| <totalChildren/> |
| <filteredElements/> |
| <avgMethodComplexity/> |
| <uncoveredElements format="raw"/> |
| <totalPercentageCovered format="raw"/> |
| <complexity format="raw" /> |
| <complexityDensity format="raw" /> |
| <coveredBranches format="raw"/> |
| <coveredElements format="raw" /> |
| <coveredMethods format="raw" /> |
| <coveredStatements format="raw" /> |
| <totalBranches /> |
| <totalClasses /> |
| <totalElements /> |
| <totalFiles /> |
| <totalMethods /> |
| <totalStatements /> |
| <ncLineCount /> |
| <lineCount /> |
| <uncoveredBranches format="raw" /> |
| <uncoveredElements format="raw" /> |
| <uncoveredMethods format="raw" /> |
| <uncoveredStatements format="raw" /> |
| </columns> |
| </current> |
| </clover-report> |
| </target> |
| {code} |
| |
| The code snippet will generate the XML reports, and the report will be captured to '$\{clover.report.dir\}/clover.xml'. |
| |
| h2. Publish Clover Report |
| Add _*Publish Clover Report*_ step to your build workflow. If you have several report sets, you can add several steps with different report set names. Reference [this page|Publish Build Reports] for more details. |
| |
| h2. Trouble Shooting |