Build succeeded but with 0% Coverage
Build succeeded but with 0% Coverage
Hi,
I am using NAnt script to run NCover, NUnit. My build gets succeeded every time w/o any errors, but the branch and symbol coverage remains 0 %. What should i do?
Please help...
NAnt script looks like this ...
<ncover program="C:\Program Files\NCover\NCover.Console.exe" commandLineExe="C:\Program Files\NUnit.2.4.8\nunit-console-x86.exe" logLevel="Verbose" commandLineArgs="E:\AmplaProjects\Applications\Trunk\Code\Testing.UnitTests\bin\Debug\Citect.Ampla.Testing.UnitTests.dll /run:Citect.Ampla.Downtime.Server.DataDelivery.DowntimeEndDataSubmission_UnitTests
/include Complete /nologo /nodots /noshadow " verbose="true" logFile="c:\Reports\Downtime\coverage.log" workingDirectory="E:\AmplaProjects\Applications\Trunk\Code" coverageFile="c:\Reports\Downtime\Unit.Test.Coverage.xml">
</assemblies>
Thanks in advance!!
RE: Build succeeded but with 0% Coverage
if you're on a 64-bit machine, you should use the ncover in "C:\program files (x86)\ncover", since you're using the x86 version of Nunit.
RE: Build succeeded but with 0% Coverage
Thank you for your response.
I changed my nunit version to nunit-console.exe but results remain same.
program output looks like this ...after running ncover from console.
[ncover] Program Output [ncover] Selected test: Citect.Ampla.Downtime.Server.DataDelivery.DowntimeEnd DataSubmission_UnitTests [ncover] Included categories: Complete [ncover] Tests run: 0, Failures: 0, Not run: 0, Time: 0.016 seconds [ncover] End Program Output [ncover] Execution Time: 177.1955 s [ncover] Symbol Coverage: 0.00% [ncover] Branch Coverage: 0.00% [ncover] Coverage Xml: c:\Reports\Downtime\Unit.Test.Coverage.xml [ncover] Coverage Log: c:\Reports\Downtime\coverage.log [ncover] Deleting settings file: C:\Documents and Settings\get0129\Local Sett ings\Temp\tmp1B.tmp.ncoversettings
BUILD SUCCEEDED
Total time: 213.8 seconds.
RE: Build succeeded but with 0% Coverage
I resolved the issue. Arguments for Nunit was the problem.
Thanks!!!