C ++ on the marketCodeMost coverage tools are charged, and coverage validator is no exception. Coverage validator should have been heard by few people.Stackoverflow. So I downloaded and tried it. If you are interested, you can go to https://www.softwareverify.com/cpp/coverage/index.htmlto learn more about the problem.
I have tried coveragemeter before, and it is quite convenient to use it. The main principle is to replace the original compiler and plug it in the code. Therefore, coveragemeter is characterized by the need to recompile the tested code. This is also a common method for most coverage tools. Coverage validator does not need to re-compile the tested code, but only needs to provide the tested binaryProgramTo calculate the code coverage. It can cover both statistical lines, branch coverage, and function coverage.
Coverage validator is also very simple to use. You only need:
1. Use coverage validator to run your tested program.
Use the menu "file"-"Start application" to specify the program to be run, and then use many options, such as program path, command line parameters, and environment variables, later, several methods were provided to start the program, such as CreateProcess, which is also the most common method.
2. view the coverage rate results in coverage validator.
It is convenient to view the results. In the code window, the lines that are overwritten and those that are not overwritten are marked by colors.
You can also:
Set filter conditions to count only the coverage data of a loaded module. For example, if you want to test a DLL, you can set a filter condition to only count the code coverage of the DLL. You can also set filtering to count only the coverage data of a class and function. The filtering method is very simple, and I will not post my own images. Menu: "Configure"-"Settings"-"filters"
The following is the interface of the referenced official website (to be honest, the interface is quite simple)
Summary Page:
Detailed results page:
Since the software is commercial and easy to use and has detailed documentation, this article does not intend to detail how coverage validator works, the purpose of this article is to let everyone know that there is such a tool that may bring you new ideas, maybe this tool is indeed useful to you.