I just installed CodeRush.
Run Test with Coverage shows coverage 0% for all tests, all projects.
Please advice what to do to make Code Coverage work.
Attached CodeRush log files
Thank you,
Enrique
I just installed CodeRush.
Run Test with Coverage shows coverage 0% for all tests, all projects.
Please advice what to do to make Code Coverage work.
Attached CodeRush log files
Thank you,
Enrique
We have addressed the issue described in this ticket and will include a fix in our next maintenance update. Should you need to apply our fix prior to official release, you can request a hotfix here.
Important Notes:
We have published the requested patched build and are looking forward to hearing about your results. Meanwhile, we would like to mark this ticket as Public, if you do not mind, to include it in the What's New lists for future maintenance updates.
Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Hello Enrique,
I looked into your log files and didn't find any potential causes of the issue. Based on our experience, such issue can appear because of your working solution specifics or because Code Coverage doesn't work on your machine.
To make sure that Code Coverage works on your machine, follow these steps:
Let us know if this helps.
We look forward to hearing from you.
Alex Eg: I have a library with a corresponding test project. I did opened the library and its tests in both VS2019 and VS2022.
In Visual Studio 2019 tests with coverage work as expected. Covered code lines are shown. No problem found.
In Visual Studio 2022 only tests work. Run Test works OK. Run test with coverage runs the tests but coverage is always 0%.
The problem is with Visual Studio 2022, version 17.3.3.
Regards,
Enrique
Hi Enrique,
Thank you for the update. In general, our Code Coverage engine has the same codebase for VS 2019 and VS 2022. So, the issue may occur due to the setup specifics of VS 2022.
Please perform the following actions:
If this doesn't help, create a simple test library in VS 2022 and run Code Coverage for it to make sure that Code Coverage is working in VS 2022 generally.
Please let me know your results.
Alex Eg:
Regards,
Enrique
Enrique,
Thank you for the update. Please clarify if you had an opportunity to try the step mentioned in my previous comment:
I look forward to your reply.
Alex Eg: sorry I forgot to do it.
I created a library with a simple function (method). Then I created a test for the library.
The test runs OK. Running the test with coverage did not work, it shows 0%.
I am working with .Net 4.8 in Visual Studio 2022.
Regards,
Enrique
Hi Enrique,
Thank you for the update. Now it's clear that the issue is project-independent. Please send us a sample project, and CodeRush (Support\Settings Folder…) and Visual Studio (Tools\Import and Export settings…) settings so we can try to reproduce the issue on our side.
Alex Eg: attached please find requested files,
Regards,
Enrique
Hi Enrique,
Thank you for the valuable information. I reproduced the issue.
At first glance, it seems that something is wrong with the MS Test support in VS 2022. We researched the issue and found that the xUnit and nUnit providers work correctly in this usage scenario.