admin管理员组文章数量:1379419
I am working with 2 C# solutions: A library project (DLL) that contains the core logic. An executor project (EXE) that runs the library by calling its methods.
I want to measure line-by-line code coverage for the library while it is being executed by the EXE. I want to do this because I want to figure out which lines are actually used for a given input. I would like to see coverage directly in Visual Studio (e.g., with covered lines in green and uncovered lines in red) as provided by the fine code coverage extension.
I installed Fine Code Coverage extension for visual studio and ran a unit test in the library solution that calles the exe.
var process = new Process {
StartInfo = {
FileName = "Path\\to\\executor.exe" }
Arguments = "Path\\to\\libconfig.json"};
process.Start();)
When I execute the unit test the exe runs the libray but no line coverage appears in the library solution except for the units tests.
本文标签:
版权声明:本文标题:c# - How to perform line coverage analysis for a library when executed by an external exe in visual studio? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744425060a2605646.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论