c# - OpenCover generates an empty report -


i using opencover determine code coverage simple c# project.

the problem

although can see mstest running unit tests (and succeeding) generated report empty.

details

this command using:

opencover.console.exe -register -arch:32                        -target:"%vsinstalldir%\common7\ide\mstest.exe"                       -targetargs:"/testcontainer:calculatortest.dll"                       -filter:+[calculator.dll]* -output:coverage.xml 

the output

microsoft (r) test execution command line tool version 10.0.30319.1 copyright (c) microsoft corporation. rights reserved.  loading calculatortest.dll... starting execution...  results               top level tests -------               --------------- passed                calculatortest.statisticstest.addoccurrencetest passed                calculatortest.statisticstest.avgtest 2/2 test(s) passed  summary ------- test run completed.   passed  2   ---------   total   2 results file:  e:\users\erno\documents\visual studio 2010\projects\codestatistics\calculatortest\bin\debug\testresults\erno_erno01 2011-07-01 14_27_06.trx test settings: default test settings visited classes 0 of 0 (nan) visited methods 0 of 0 (nan) visited points 0 of 0 (nan) 

the content of generated report:

<?xml version="1.0" encoding="utf-8"?> <coveragesession xmlns:xsd="http://www.w3.org/2001/xmlschema"                  xmlns:xsi="http://www.w3.org/2001/xmlschema-instance">     <visitpoints /> </coveragesession> 

environment

the code running on windows 7 64-bits executed in 32-bit visual studio command prompt environment.

edit running command in directory debug build of unit tests , added opencover directory environment path.

what tried

i searched similar problems partcover (because opencover appears sort of branch) not find matched problem , presented solution.

edit tested broader filter -filter:+[*]* did not change output in way.

edit tested mstest /noisolation argument as mentioned here. still no results.

edit tested removing filter , falling default filter. no results.

you should able use -register:user switch per user registration i.e. registers (and unregisters) without needing full admin rights.


Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -