JetBrains.ReSharper.TaskRunnerFramework.dll中的'System.IO.EndOfStreamException'

问题描述 投票:5回答:1

[尝试在调试模式下运行非常基本的xunit测试时,我的测试项目抛出了一些异常,这些异常似乎来自ReSharper。

Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
Could not find file 'C:\Temp\test\TestProjekt\TestProjekt\bin\Debug\TestProjekt.xunit.runner.json'.

Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
Could not find file 'C:\Temp\test\TestProjekt\TestProjekt\bin\Debug\xunit.runner.json'.

Managed Debugging Assistant 'LoadFromContext' 
The assembly named 'xunit.runner.utility.net452' was loaded from 'file:///C:/Program Files (x86)/JetBrains/Installations/ReSharperPlatformVs15_0a4dd3ad/xunit.runner.utility.net452.dll' using the LoadFrom context. The use of this context can result in unexpected behavior for serialization, casting and dependency resolution. In almost all cases, it is recommended that the LoadFrom context be avoided. This can be done by installing assemblies in the Global Assembly Cache or in the ApplicationBase directory and using Assembly.Load when explicitly loading assemblies.

testException thrown: 'System.Threading.ThreadAbortException' in xunit.execution.desktop.dll
Thread was being aborted.

Exception thrown: 'System.Threading.ThreadAbortException' in xunit.execution.desktop.dll
Thread was being aborted.

Exception thrown: 'System.Threading.ThreadAbortException' in mscorlib.dll
Thread was being aborted.

Exception thrown: 'System.UnauthorizedAccessException' in mscorlib.dll
Access to the path 'TestProjekt.PDB' is denied.

[...]

Exception thrown: 'System.UnauthorizedAccessException' in mscorlib.dll
Access to the path 'TestProjekt.PDB' is denied.

Exception thrown: 'System.IO.EndOfStreamException' in JetBrains.ReSharper.TaskRunnerFramework.dll
Attempted to read past the end of the stream.

The program '[14628] JetBrains.ReSharper.TaskRunner.CLR45.x64.exe: Program Trace' has exited with code 0 (0x0).
The program '[14628] JetBrains.ReSharper.TaskRunner.CLR45.x64.exe' has exited with code 0 (0x0).

到目前为止我尝试过的:

  • 将项目从默认配置文件文件夹移至c:\ temp ...
  • 使用本地管理员权限启动Visual Studio 2017
  • 将ReSharper更新到当前可用的最新版本(2018.2.1)
  • 清除ReSharper缓存
  • 清理整个解决方案
  • 创建新的空类库项目,然后再引入xunit nuget包(.NET Framework 4.7.2)
  • 降级.NET Framework 4.7解决方案
  • 重新安装ReSharper并选择“为所有用户安装”,而不是仅为我的用户安装,以确保我的配置文件中没有剩余的内容...

似乎可以调试相同的测试项目,而在队友的工作站上没有任何问题...因此,我的安装肯定有问题。

我在这里做错了什么?有什么想法吗?

c# exception resharper xunit
1个回答
0
投票
中的'System.IO.FileNotFoundException'

在Visual Studio中启用Just my Code至少可以阻止此第一个Chance异常使我的输出混乱。因此,这是一种解决方法...

© www.soinside.com 2019 - 2024. All rights reserved.