Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Improve Code Coverage Markers to be on par with Visual Studio 2013
Micah71381
#1 Posted : Wednesday, March 12, 2014 12:36:46 AM(UTC)
Rank: Member

Groups: Registered
Joined: 10/18/2013(UTC)
Posts: 27
Location: United States of America

Was thanked: 2 time(s) in 2 post(s)
Visual Studio 2013 Ultimate's Code Coverage markers are more accurate than NCrunch's markers. In this simple example, you can see that NCrunch says that I have 100% code coverage of MyMethod while Visual Studio more correctly shows me that I have not covered all code paths. This encourages me to go with VS's solution, though I would really prefer to stay with NCrunch.

http://snag.gy/oGfDa.jpg

On a related note, I like the inline highlighting done by VS2013, though I don't like the loss of syntax highlighting when it is enabled. It would be neat if NCrunch did inline highlighting but only a bordered highlight so the text retained its syntax highlighting yet I could get green/red/white boxes around code that is passing/failing/uncovered. Perhaps if the whole function was covered the box would go away and be replaced with the "1/1 passing" above it like VS2013 or something. This would encourage me to reach 100% coverage so that my functions don't have colored boxes everywhere. :D
Remco
#2 Posted : Wednesday, March 12, 2014 2:08:31 AM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,161

Thanks: 964 times
Was thanked: 1296 time(s) in 1202 post(s)
Hi, thanks for posting and for the feedback.

NCrunch is somewhat limited in its code coverage analysis by the fact that it only analyses line-by-line, whereas more specialised code coverage tools (such as the one in Visual Studio) will analyse any statement or code component with debugging information available.

The line-by-line decision was made in an effort to provide better performance while processing large amounts of code coverage, and to try to maintain simplicity through the UI.

There have been many good suggestions about how NCrunch might able to provide better visual representation of partial-line coverage (for example, perhaps by having a half-coloured marker). Although these suggestions certainly have merit and I can appreciate the value of making the coverage more accurate, at the moment this area isn't really a design goal and the structural limitations of NCrunch's processing would make it very difficult to implement without greatly decreasing the performance of the engine.

Of course, things always change. There is always the possibility to pursue this later in future.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

YAF | YAF © 2003-2011, Yet Another Forum.NET
This page was generated in 0.026 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download