Coverge Highlighting not working in dotCover

Answered

I'm trying to compare dotCover with NCrunch, and one of the problems I'm having with dotCover is that it doesn't highlight any lines at all, no matter what I do.  I have a set of tests with some code coverage using xUnit with the ReSharper xUnit plugin ( I also made one with nUnit and it worked the same).  I get code coverage results that seem to be accurate, but I've tried turning highways and on both the main user menu on the toolbar in the code coverage window – neither with any effect.

I thought it might be a conflict with NCrunch, so I removed it and still have the same effect.  It seems like the menu item should be a toggle, but it never gets a checkbox or any other indication that it is turned on or off, nor does the button on the toolbar in the code coverage navigate.

I'm using Visual Studio 2013 Visual Studio 12.0.21005.1., with JetBrains ReSharper 8.2 Full Edition Build 8.2.0.2160, and JetBrains dotCover 2.7.1 Full Edition Build 2.7.1.218 .

I made a tiny test project in Visual Studio 2010 that never had NCrunch installed, and it doesn't work either.

Any suggestions?

0
8 comments

Hi Wade,

Thank you for contacting us.
Could you please check the following:

- the code you're interested is built with PDBs.
- the code is not filtered out by coverage filters.
- paths to the source files are not changes since the moment when the  coverage snapshot was created .

Also, make a HTML report via "Export coverage report...", open it and check if there is highlighting for the code in the right part.

Regards,
Fedor.



Attachment(s):
2014-05-21_1819.png
0
Avatar
Permanently deleted user

- Everything has PDBs, and the source hasn't moved
- The HTML report has green highlights like the attached snapshot
- The Show Covering Test command works
- The Toggle Code Highlighting command looks like it's a tobble, but it never acquires a checkbox or anything like that when I click it.
- Tried executing  dotCover.dotCover_ToggleHighlighting in the Command Window with no results
- Turned off ALL filters
- Checked Highlighting Options - It's 'Shady'.  Tried others, and even the standard white VS theme with no change

Note that I'm using xUnit via the xUnit Resharper Plugin, which the docs say should be ok.

Anything else to check?



Attachment(s):
Snap13.png
0

Hi Wade,

We had the same issue with ReSharper previously and here is a workaround: http://resharper-support.jetbrains.com/entries/26859128-ReSharper-Fonts-Colors-settings-do-not-appear-in-Visual-Studio-after-installation
Could you please try it and let me know the results.
Sorry for the inconvenience.

Regards,
Fedor.

0
Avatar
Permanently deleted user

Same result.  I had the color settings in theOptions | Fonts and Colors before, but was hoping that would fix something so I could make the Templates Explorer readable.  Didn't really change anything in DotCover.

Is the "Toggle Code Highlighting" menu item supposed to put some kind of visible marker when it's enabled?  I would expect a check in the icon area, or something like that but nothing changes.  I also ran the toggle command manually a few days ago and that didn't seem to do anything.

Any other ideas?

0

Hi Wade,

We prepared a custom build with additional logging: http://download.jetbrains.com/dotcover/dotCoverSetup.2.7.2.13.msi
Please install it and run Visual Studio with       the following command line:

  'devenv /dotCover.LogFile path_to_the_log_file       /dotCover.LogLevel Verbose'

after that run coverage analysis, close VS and send us       a resulting log file.
Thanks in advance.

Regards,
Fedor.

0
Avatar
Permanently deleted user

Just for the benefit of anyone else who may stumble upon this having the same issue - I thought code coverage wasn't working for me after upgrading from ReSharperUltimate.2016.2.2 to ReSharperUltimate.2016.3.1, but turned out the style of the highlighting has changed and is now much more subtle - so subtle in fact I didn't even notice it until it was pointed out by a colleague. There are now little grey/green vertical dashes that look like slimline led lights up the left-hand side of the code, it no longer highlights the entire line of code in red or green. This doesn't appear to be configurable in any way, other than option to enable/disable...

1

@Breenlough, thanks for this. I assume they made this change to make it easier to allow leaving code highlighting on all the time, but I would much rather it highlight the whole line and have to turn the highlighting on/off when I want to.

0
Avatar
Permanently deleted user

@Breenlough/@Mike Schuld: At least for ReSharper Ultimate 2017.1 there is an option to configure the way it highlights the code.

dotCover Options -> Highlighting -> Highlight code coverage using:
- Markers in the left gutter
- Line background
- Both markers and line background

2

Please sign in to leave a comment.