Generation of Reports

Note: This feature is not available for black box testing.


The menu entry "ReportsGenerate HTML/CSV Report…" allows to export code coverage statistics (per methods, source files, executions, …) of the selected executions in HTML format. It allows also to list the manually validated and unexecuted code parts.


Selecting the menu entry "ReportsExport Statistics in EMMA-XML Format…" allows exporting code coverage statistics of in EMMA-XML format. The output contains global statistics in a format that is compatible with EMMA. This allows using Squish Coco in tools that provide support for EMMA, notably to give an easy way to use Squish Coco with continuous integration servers like Jenkins CI.

EMMA defines four categories for coverage: classes, methods, blocks, and lines. With Squish Coco they have the following meaning:

EMMA categoryMeaning
classesA class is considered executed if one of its method is called. Code which is not in a class is located in the class "" (empty).
methodsA method is covered if it was called.
blocksCode coverage at statement block level.
linesLine code coverage (if compiled with line coverage support).
conditionsDecision/Condition coverage (if compiled with Decision/Condition coverage support).

Cobertura XML Report

The menu entry "ReportsExport Statistics in Cobertura-XML Format…" allows exporting code coverage statistics in Cobertura-XML format. The output contains global statistics in a format that is compatible with Cobertura. This allows the use of Squish Coco in tools that provide support for Cobertura, notably giving an easy way to use Squish Coco with continuous integration servers like Jenkins CI and SonarQube.

The statistics in the Cobertura report is computed a little bit differently from the usual way due to the limitations of the report format. The report is in fact a combination of line and condition coverage.

Every statement block, decision and condition instrumentation is counted as a Cobertura-condition. The end of a function is e.g. marked as one condition to fulfill.

The report format also requires that each line with a condition is also instrumented at line coverage level. This is not always true (e.g. with empty functions), so in this case we artificially add some instrumentation values. Finally, if an instrumented statement is spans more than one line, it is necessary to generate instrumentation data for each line.

All this has an impact on the computation of the statistics for classes, methods and sources, but the resulting values are comparable to those in the other report formats.

JUnit Report

The menu entry "ReportsExport JUnit Report…" allows exporting the test result as JUnit report. This report does not contain coverage data and only lists the test execution result (i.e. "passed" or "failed") for each test item.

Text Report

Clicking on the menu entry "ReportsGenerate Text Report…" generates a small text report in the form of one line per executed/unexecuted item. A distinct line format can be specified for executed or unexecuted lines.

The following escape sequences are recognized:

  • %f: Absolute source code file name
  • %r: Relative to the current build directory source code file name
  • %l: Line number
  • %c: Column number
  • %m: Explanation
  • %t: Source code fragment
  • %e: List of tests executing the instrumentation

Example: Setting the field "Unexecuted Code Fragments" to "%f:%l: %m" will create a text file which contains all unexecuted code parts. Each line will look something like this:

    foo.cpp:55: Unexecuted: 'return;'

© 2022 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.