Command | Description |
---|---|
| Converts raw coverage input (.map, .clog) into coverage data files (.cov): cpptestcov compute -map=<COV_MAP_ROOT_DIR> -clog=<COV_LOG_FILE> -out=<COV_DATA_DIR> Use Example: cpptestcov compute -map=.cpptest/cpptestcc -clog=cpptest_results.clog -out=cov-data-run1 |
| Creates an index file (coverage.index) for a given coverage data folder: cpptestcov index <COV_DATA_DIR> Note: The coverage data folder needs to be indexed to present coverage data in Visual Studio Code. Example: cpptestcov index cov-data-run1 |
| Merges multiple coverage data folders: cpptestcov merge <COV_DATA_DIR_1_IN_OUT> <COV_DATA_DIR_2_IN> <COV_DATA_DIR_3_IN> ... Be sure the Example: cpptestcov merge cov-data-cumulative cov-data-run1 cov-data-run2 |
| Computes coverage numerical values for coverage data folder: cpptestcov query <COV_DATA_DIR> ... Query type can be defined with the Example: cpptestcov query -coverage LC cov-data-run1 cpptestcov query -coverage MCDC -type covered,total -element /home/project/file.cpp cov-data-run1 |
| Applies coverage suppressions for a given coverage data folder: cpptestcov suppress <COV_DATA_DIR> Coverage suppressions should be added directly to the tested code - as a code comment: // parasoft-cov-suppress "Reason for suppressing coverage for this line" or provided with a regular expressions defining lines to be suppressed. See also: Suppressing Coverage. Example: cpptestcov suppress cov-data-run1 cpptestcov suppress --regex ".DEBUG." cov-data-run1 cpptestcov suppress --regex-cov-reason ".while(1)." DC "ignore decision coverage for while(1)" cov-data-run1 |
| Prints Line Coverage statistics in Cobertura format: cpptestcov report cobertura <COV_DATA_DIR> Example: cpptestcov report cobertura cov-data-run1 > cobertura.xml |
| Publishes coverage and GoogleTest results to Parasoft DTP: cpptestcov report dtp <COV_DATA_DIR> <GOOGLE_TEST_REPORT_XML> Example: cpptestcov report dtp -settings dtp.properties cov-data-run1 gtest-test1.xml gest-test2.xml Be sure to configure DTP parameters using a settings file; see Publishing Reports to Parasoft DTP. |
| Generates a coverage report in HTML format: cpptestcov report html <COV_DATA_DIR> Example: cpptestcov report html cov-data-run1 To include source code with coverage annotations, use the Examples: cpptestcov report html -code -out report/run1.html cov-data-run1 cpptestcov report html --single-page -out coverage-stats.html cov-data-run1 |
| Prints coverage data folder statistics in JSON format: cpptestcov report json <COV_DATA_DIR> Example: cpptestcov report json cov-data-run1 > report.json |
| Prints Line Coverage statistics in lcov format: cpptestcov report lcov <COV_DATA_DIR> Example: cpptestcov report lcov cov-data-run1 > lcov.info |
| Prints coverage data folder statistics in Markdown format: cpptestcov report markdown <COV_DATA_DIR> Example: cpptestcov report markdown cov-data-run1 > report.md |
| Prints the MCDC truth-tables for a given coverage data folder: cpptestcov report mcdc <COV_DATA_DIR> Example: cpptestcov report mcdc cov-data-run1 |
| Prints the lines with suppressed coverage for a given coverage data folder: cpptestcov report suppressed-lines <COV_DATA_DIR> Example: cpptestcov report suppressed-lines cov-data-run1 |
| Prints the suppressed coverage elements for a given coverage data folder: cpptestcov report suppressions <COV_DATA_DIR> Example: cpptestcov report suppressions cov-data-run1 |
| Prints coverage data folder statistics: cpptestcov report text <COV_DATA_DIR> Example: cpptestcov report text cov-data-run1 |
| Prints the uncovered lines for a given coverage data folder: cpptestcov report uncovered-lines <COV_DATA_DIR> Example: cpptestcov report uncovered-lines cov-data-run1 |
Overview
Content Tools