This project is read-only.

Possible support for C++ class coverage?

Sep 20, 2016 at 4:25 AM

With more and more use of your open source software, I feel very excited that I can configure it to do many interesting things, like: Show which line is covered by which test cases run by our application. Thank you very much for open source the great software!

There is one more thing that I would like to ask for your idea:
Is it possible to get C++ class coverage for my application? For example, I need to gather data about which C++ class has enough coverage and which cpp class has no coverage.

The current coverage rate is measured by source file and source lines. It's great but, I feel a little hard to dig into more detailed C++ class information.

Sep 24, 2016 at 1:44 PM

I am currently working hard to have a nice plugin and hope I can release it soon.
When it will be done, I will add new features to OpenCppCoverage. My idea is to provide a kind of plugin interface so that everyone can customerize the output.

In the meantime, you can try to use the following command:
"C:\Program Files (x86)\Windows Kits\8.1\Debuggers\x86\dbh.exe" YOUR_PDB dump
This will dump all symbols with source file and line. So, if you run OpenCppCoverage and exports the coverage in xml, you should be able to know for a source and a line the symbol (Example CppCoverage::Debugger::OnCreateProcess).

I hope this will help,

Marked as answer by OpenCppCoverage on 4/8/2017 at 4:38 AM
Sep 28, 2016 at 10:58 AM

Thank you for the good suggestion. I noticed that I didn't have Debugging tools for windows installed and then I downloaded the toolkit and installed them. I really find all the class information in a specified dll by typing the command. I think I will learn more about the dbh tool and find a method to bind the class information with code coverage report.

Thanks again for your support!