Codecov_to_cobertura.py is a python script to convert from XML produced by Intel's codecov tool to Cobertura XML format.
This format can be read by e.g. Hudson/Jenkins to generate coverage reports.
See e.g. intel.com for more info on codecov.
- Compile your C++/Fortran code with the
-prof-gen=srcposflag. - Run your program (possibly with various inputs to cater all scenarios), which produces
.dynfiles. - Use the
profmergetool to merge one or more.dynfiles intopgopti.dpi. - The
codecovtool can now be used:codecov -prj <projectname> -dpi pgopti.dpi -spi pgopti.spi -xmlbcvrg codecov.xml, which should produce an XML filecodecov.xml - Finally the
codecov_to_cobertura.pyscript can be used to generate a Cobertura XML file:python codecov_to_cobertura.py codecov.xml <src_path> <object_path> coverage.xmlwhere<src_path>and<object_path>are the paths to your source and object files, respectively.
For more description of the command-line arguments to codecov_to_cobertura.py, try codecov_to_cobertura.py -h.
- Has only been tested on Linux.
- Uses
nmto list symbols in object files. - Use at your own risk.