New and up to date documentation required

New and up to date documentation required

1) No documentation provided with installation

2) Only documentation provided is a very out of date FAQ

3) Running the NCover.Console app gives the following inconsistent message:

Usage: ncover.console [<command> [<command args>]]
                      [//svc <service name>]
                      [//iis] [//v] [//q]
                      [//a <assembly list>] [//l <log file>]
                      [//o <coverage output>]
                      [//s [<settings file>]] [//r [<settings file>]]
                      [//w <working directory>]

       Example command line to launch profiled application
         ncover.console myapp.exe arg1 arg2
         ncover.console //svc MyService
         ncover.console //iis

       NOTE: Any command line parameters that do not start with '//'
             are passed to the profiled application on its command line.

//a    List of assemblies to profile separated by semi-colons
        i.e. "MyAssembly1;MyAssembly2"
//w    Working directory for profiled application

//l    Specify profiler log file
//x    Specify coverage output file
//h    Specify HTML report output path

//s    Save settings to a file (defaults: NCover.Settings)
//r    Use settings file, overriding other settings (default: NCover.Settings)

//q    No logging (quiet)
//v    Enable verbose logging (show instrumented code)

 


Re: New and up to date documentation required

I'd love to see some quick documentation on how to run this, too.  Can you use long directory/file names?  Can you just put the settings in another file so that the command line isn't such a mess?


Re: New and up to date documentation required

You can create a settings file from the command line or create a settings file using your favorite text editor.  Either way, here is how to use it.

Command line to create the settings file:
NCover.Console //a "ASSEBLY1;ASSEMBLY2;" //w "C
:\Projects\CommonFramework.NET\install"  "C:\tools\nant-0.85-nightly-2005-12-13\
bin\NAnt" //s

Command line to use the settings file:
C:\Program Files\NCover>NCover.Console //r

NCover.Settings file:
<?xml version="1.0" encoding="utf-8"?>
<ProfilerSettings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">;
  <CommandLineExe>C:\tools\nant-0.85-nightly-2005-12-13\bin\NAnt</CommandLineExe>
  <Assemblies>ASSEMBLY1</Asseblies>
  <Assemblies>ASSEMBLY2</Asseblies>
  <LogFile>Coverage.Log</LogFile>
  <CoverageXml>Coverage.Xml</CoverageXml>
 <WorkingDirectory>C:\Projects\CommonFramework.NET\install</WorkingDirectory>
  <VerboseLog>false</VerboseLog>
  <ProfileIIS>false</ProfileIIS>
  <DumpOnErrorNormal>false</DumpOnErrorNormal>
  <DumpOnErrorFull>false</DumpOnErrorFull>
  <NoLog>false</NoLog>
</ProfilerSettings>


Re: New and up to date documentation required

I followed you directions and created the settings file shown below. When I run ncover.console //r I get "The system cannot find the path specified" along with the other status message (which I will show at the bottom of this post.)  Any clue as to how I might determine which path is not found?

 

****** ncover.settings **************

<?xml version="1.0" encoding="utf-8"?>
<ProfilerSettings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <CommandLineExe>C:\Program Files\NUnit-Net-2.0 2.2.8\bin\nunit-console.exe ..\..\bin\debug\arithmeticunittest.dll /config=..\..\arithmetic.nunit</CommandLineExe>
  <Assemblies>ArithmeticMvp.dll</Assemblies>
  <LogFile>Coverage.Log</LogFile>
  <CoverageXml>Coverage.Xml</CoverageXml>
  <WorkingDirectory>C:\Documents and Settings\GSills\My Documents\Visual Studio 2005\Projects\EnvExamples\ArithmeticUnitTest\bin\Debug</WorkingDirectory>
  <VerboseLog>false</VerboseLog>
  <ProfileIIS>false</ProfileIIS>
  <DumpOnErrorNormal>false</DumpOnErrorNormal>
  <DumpOnErrorFull>false</DumpOnErrorFull>
  <NoLog>false</NoLog>
</ProfilerSettings>

 

***** Output from nocover.console //r *****************

Command: C:\Program Files\NUnit-Net-2.0 2.2.8\bin\nunit-console.exe ..\..\bin\d
bug\arithmeticunittest.dll /config=..\..\arithmetic.nunit
Command Args:
Working Directory: C:\Documents and Settings\GSills\My Documents\Visual Studio
005\Projects\EnvExamples\ArithmeticUnitTest\bin\Debug
Assemblies: ArithmeticMvp.dll
Coverage Xml: Coverage.Xml
Coverage Log: Coverage.Log

The system cannot find the path specified


Re: New and up to date documentation required

Most likely the problem will be the space in the paths (for example to NUnit). Use short names or make use of quotes around the paths.

Grant.
http://ncoverexplorer.org/


Re: Empty HTML Coverage folder

No, the HTML coverage folder is not being populated yet, but I am working on it.


Re: Empty HTML Coverage folder

ok, thanks. The XML/XSL does the job for now anyway. Thanks.


Re: Empty Output file when using assembly list from variable!

I don't know of any reason why that wouldn't work.  The NCover program is agnostic as to how the variable gets put onto the command line.  Can you check the actual command line that is passed to the NCover.Console program and see if the variables are being replaced correctly?


Re: Empty Output file when using assembly list from variable!

By the way, you can use 1.5.0 for your 1.1 code.  There is no need to move your code onto the 1.1 framework at this time.  I just posted a blog post about this http://ncover.org/SITE/blogs/ncover_blog/archive/2006/01/18/39.aspx.


Re: Filter to show not satisfied results only

Nice idea Thomas, I will add it to the list - might even make it to 1.3.5 depending on how long it is before I release it... The biggest difficulty with a feature like this is coming up with the right icon...


Re: Filter to show not satisfied results only

Thomas,

I couldn't resist adding this to the NCoverExplorer 1.3.5 beta. Please test it and let me know if it fits the bill. Download details are in this thread: http://ncover.org/SITE/forums/thread/560.aspx


Re: Filter to show not satisfied results only

Hi Grant,

the feature is exactly what I expected.

Thx a lot, Ciao
Thomas


Re: Report Type Option In Console.exe

Try /r:4 rather than /r4


Re: Report Type Option In Console.exe

It worked, thanks.


Re: &quot;Problem while displaying the following code&quot; - Phantom meth

Alexander,

The module with the empty name for "assembly" is to do with multiple AppDomains and an issue with NCover. This is exactly what the main holdup on the NCover 1.5.5 release is for - Peter is changing some of the code related to identifying the assembly being profiled so as to remove the duplicate sections in the coverage output.

That said - NCoverExplorer should cope with such sections in NCover 1.5.4 or earlier as what it does is "merge" the coverage results together. You may notice that first section has a whole lot of visit counts set to zero.

Which version of NCoverExplorer are you using? If that is the complete error output then it is a very old one (as the error message from about 1.3.3 or so should have a version number in the error output).

I highly recommend you try either NCoverExplorer 1.3.4 or even my latest beta 1.3.5 - both links are available on my blog at link in signature. Let me know if you still have a problem with those versions.


Re: &quot;Problem while displaying the following code&quot; - Phantom meth

Thanks for the quick reply.

I'm using NCover 1.5.4, and NCoverExplorer 1.3.5.1759 as bundled with TestDriven.net.

To further specify, if I click a class in the tree view on the left, which contains some of these phantom methods that no longer exist, it first gives me a "Resolve Missing Source Code File" dialog, which I personally find a bit confusing. After I close this dialog (for example by clicking Skip), it gives me the error dialog I mentioned in my original post. Here's a screenshot of the dialog:

http://pils.r1hosting.net/pics/ncoverexplorer_error.png

If you want, I can mail you a copy of the code I'm trying this out with, then you can see if you can repro the error.


Re: &quot;Problem while displaying the following code&quot; - Phantom meth

Hi mate,

Sounds like you do have pretty close to the latest version which is good - eliminates us looking into something long ago fixed!

The http link is broken for me - but if you are able to send me some repro code that would be fantastic. My e-mail address is on the Help->Send Feedback link in NCoverExplorer - I will take a look tonight and let you know what I find.


Re: &quot;Problem while displaying the following code&quot; - Phantom meth

I finally solved the problem. It was due to my code using Reflection on an obsolete DLL (hardcoded path in my code), which I had forgotten about.