dotCover highlighting not working after upgrade to 2016.2.2


After upgrading to ReSharper 2016.2.2, the dotCover coverage highlighting doesn't seem to work correctly. Code in the test project is highlighted correctly, but the code that's actually getting tested is not. For example:

Test Project:

Actual Code:

So far, I've tried:

  • Cleaning/fully rebuilding the solution
  • Clearing the ReSharper cache for the solution
  • Reinstalling dotCover
  • Removing and re-adding solution project references to the test project
  • Checking that the PDB files are correctly being copied into the test project build folder (they are)
  • Debugging tests to make sure that the code is actually being called (it is)

Everything worked correctly before this upgrade. Could anybody offer any suggestions, please? Coverage highlighting was an extremely useful feature!

Comment actions Permalink
Official comment

Before applying code highlighting, dotCover 2016.2 checks whether any source files were modified since the last coverage snapshot was created. To perform the check, dotCover compares current source file checksums with the checksums in PDB files used for coverage analysis. It appears that some third-party applications/extensions change or delete these checksums from PDB files during assemblies post-processing. Currently, the issue is confirmed for PostSharp, Mr.Advice and CodeContracts. In dotCover versions prior to 2016.2, checksums check is not performed which leads to incorrect highlighting: highlighted statement ranges don't correspond to the current source code state.
Do you use any tool that performs assemblies post-processing?

We’ve opened a feature request for an option to provide highlighting without checking checksums (as it was in the previous versions):
This feature is already implemented and will be available in the next ReSharper 2016.3 EAP build, namely EAP 3:
Sorry for the possible inconvenience.

Comment actions Permalink

I am surprised that you would call this a "possible" "inconvenience" -- being able to analyze code coverage is the main reason for many people to use ReSharper.

Comment actions Permalink

I can confirm that highlighting appears to work again with the EAP version and the 'Require source files to exactly match...' option unchecked. Thanks!

Comment actions Permalink

Visual Studio highlighting still doesn't work in EAP 7.  If I export to HTML I see all highlighted code correctly, but that is a lame workaround.


Please sign in to leave a comment.