Unit testing 获取.net核心xUnit项目中的代码覆盖率

Unit testing 获取.net核心xUnit项目中的代码覆盖率,unit-testing,asp.net-core,.net-core,code-coverage,xunit.net,Unit Testing,Asp.net Core,.net Core,Code Coverage,Xunit.net,我正在尝试使用来自的指导来获得.net核心项目中的代码覆盖率 测试工作正常 但是,当我添加代码覆盖率选项时,会出现以下错误: Starting test execution, please wait... Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. Object reference not set to an

我正在尝试使用来自的指导来获得.net核心项目中的代码覆盖率

测试工作正常

但是,当我添加代码覆盖率选项时,会出现以下错误:

Starting test execution, please wait...
Unable to read data from the transport connection: An existing connection was 
forcibly closed by the remote host.
Object reference not set to an instance of an object.


也许有人经历过这个问题,可以分享如何修复它的知识?

当我尝试以管理员身份运行powershell时,这个问题消失了,所以我想这与访问权限有关