Default language.

Code Coverage tab


There are two ways to collect code coverage:

  1. Collect code coverage by using Code Debug

    • Default. If no Code coverage daemon data is specified at the connection in scope for the execution code coverage will be collected by Code Debug.
    • Initially, Code Coverage with Code Debug is only supported for batch.
  2. Collect code coverage by using IBM Debugger

    • Will be activated in the Execution Context dialog box if the connection definition in the Repository server includes values in the fields "Collector ip address" and "Collector port" in the section Code coverage daemon.

Code Debug Code Coverage

If option 1 (Code Debug) is in scope, the Code Coverage tab will have the following layout:

pg46_1.png

To collect code coverage:

  1. Check the "Collect Code Coverage" checkbox.
  2. Specify the Repository data set where Code Debug will write coverage information. This data set will later be fed into the Code Coverage reporting system to report on program invocations that occurred during the test session. Members with like systems, names, and compile date and times will automatically be merged together.
  3. Specify or select a System name for this test. The System name drop down contains a list of recently used system names. Code Coverage keeps statistics by programs separated by system name. This name can be any user-specified name.
  4. Specify or select a Test ID to be added to the Code Coverage test. This information can be useful when reviewing test reports from Code Debug/Code Coverage.
  5. Check the "Clear existing statistics before running the test" checkbox to clear the statistics in the provided Repository, System and Test ID before the test is executed.
    Uncheck this option to keep any existing repository statistics.

IBM Debugger Code Coverage

If option 2 (IBM Debugger) is in scope the Code Coverage tab will have the following layout:

pg47_1.png

Type of Session

Select NoneCollect Code Coverage or Start debug session for the type.

Code Coverage information will be generated and collected when this option is enabled. It requires a code coverage daemon to be running and configured for the environment/connection that is used. It is also possible to manually enter the daemon ip:port in the dialog box.

Start Debug Session

By enabling the Start debug session it is possible to define your machine ipaddress and port on which the debugger is listening, and then trigger a debug session in your IDE when executing the test scenario. This can be valuable if a test fails and you at runtime want to examine what goes wrong.

Start debug session will only start automatically for batch. If debug of a CICS execution is requested, logon to the CICS and activate the debug from there. Then start the test execution for the CICS environment.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*