Control Coupling Report

After you build a project with HCL DevOps Test Embedded (Test Embedded), you can get a Control Coupling report with compilation unit module or a Control Coupling report with function module, depending on the build settings.

The default Control Coupling report is in HTML format. It is generated from a template named ccreport.template (for the module as compilation unit option ), or ccfreport.template (for the module as function option). The templates are provided as text files that you can modify to customize the report. It uses four online JavaScript libraries:
  • Bootstrap,
  • JQuery,
  • Font Awesome,
  • VisJS.
These libraries are not provided. You must have an internet connection when you open the report. If not, download the libraries (.css and .js files), copy them in the same folder than your report, and modify the template file as follows:
Replace the following lines with the lines from the second text block:
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/vis/4.21.0/vis.min.css">
…
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/vis/4.21.0/vis.js"></script>
Replacement lines:
<link rel="stylesheet" href="./bootstrap.min.css>
<link rel="stylesheet" href="./all.css">
<link rel="stylesheet" href="./vis.min.css">
…
<script src="./jquery-3.3.1.slim.min.js"></script>
<script src="./popper.min.js"></script>
<script src="./bootstrap.min.js"></script>
<script src="./vis.js"></script

If you set a module as a compilation unit in the control coupling properties, you get a control coupling report with compilation units in output of your project build. If you set a module as a function, you get a control coupling report with function in output. For more details about the control coupling settings, see Set Control Coupling options for Test Embedded for Eclipse IDE. In a report with function as module, the report shows all the function calls (internal and external).

The Control Coupling report includes three parts.

Summary

In the Summary section, you find the number of Control Couplings for your application that are covered, given the information that you provided and the percentage of Control Couplings that are covered.

A graph displays the total percentage of covered and non covered control couplings for the entire application.

The Summary table displays the following information:
  • The percentage of Control Couplings of your application by module pairs that have not been covered, depending on the information that you provided.
  • The percentage of Control Couplings that are covered by module pairs.
Control Coupling Report - Summary

Details

The Details table lists all the Control Couplings and displays the following information for each of them:
  • The calling compilation unit.
  • The control flow, for example: the successive calls in the module that end with the external call in the called module. Note that the called module is mentioned in the last function of the control flow. In case of option "module as function", this control flow contains only two functions.
  • A check mark if it is a longest Control Flow but only if the "module as compilation unit" option is set.
  • A check mark if it is a shortest Control Flow but only if the "module as compilation unit" option is set.
  • The list of test cases that covered this control flow. If the Control Coupling feature is set with the unit testing feature, the test cases are the one in the .ptu files named as <service>/<test>.
  • The associated requirements. If the Control Coupling feature has been set with the unit testing feature, the requirements are those that have been described in the .ptu files with the keyword REQUIREMENT for each test cases that covered this Control Coupling.
  • A check mark if the control coupling has been covered.

Call Graph

For each compilation unit, a partial call graph displays all the functions in an interactive call graph from left to right or from top to bottom, depending on the selector button position on the top of the call graph.

You can select a control coupling in the table to highlight it in the call graph.Control Coupling Report - Call Graph
At the end of the report, a complete call graph displays all the functions calls.

Filters

You can apply filters in the report by selecting different options at the top:

  • If the option “module as compilation unit" option is set, you can choose first to display all Control Couplings, the longest (only the Control Couplings that have the longest control flow in the calling module) or the shortest (only the Control Couplings that have the shortest control flow in the calling module). The summary tables and the details table are updated accordingly to your selection. This option applies to reports with compilation unit as module only.
  • You can select the calling modules and the called modules. It filters the Control Couplings depending on their calling and called modules. The summary tables and the details table are updated accordingly to your selection.
  • You can choose to display all graphs or hide them in the report.
  • You can show or hide the Requirements.