0

I am new using Opencover and I would like to know if it is possible to use it with CMake tests because my project is already using it.

mkdir build    
cd build
cmake ..    
cmake --build . --config Debug
..\tools\OpenCover.4.6.519\tools\OpenCover.Console.exe -target:"C:\Program Files (x86)\CMake\bin\cmake.exe" -targetargs:"--build . --target RUN_TESTS --config Debug"

And the corresponding error:

Committing...
No results, this could be for a number of reasons. The most common reasons are:
     1) missing PDBs for the assemblies that match the filter please review the
     output file and refer to the Usage guide (Usage.rtf) about filters.
     2) the profiler may not be registered correctly, please refer to the Usage
     guide and the -register switch.

I tried to add the switches targetdir and/or searchdirs to bin\Debug and also register but with the same result.

Do you have any idea on solving this?

Thanks for your help!

ABotella
  • 83
  • 1
  • 7

1 Answers1

0

OpenCover only works for .net project running on the windows .net runtime.

Shaun Wilde
  • 8,228
  • 4
  • 36
  • 56
  • Thank you for your answer. Do you know a coverage tool that I could use on windows? I have a set of executables to test my project. – ABotella Nov 15 '16 at 07:49
  • There are some commercial ones but I don't know what language you are dealing with to help you further. – Shaun Wilde Nov 15 '16 at 09:52