unit-testing - ReSharper 运行单元测试但位置错误且缺少配置文件 (ApplicationBase)

标签 unit-testing nunit resharper

当我从 ReSharper 运行单元测试时我的 AppDomain.CurrentDomain.SetupInformation有路径:C:\Users\%USERNAME%\AppData\Local\Temp\hwa3yebt.mas\<project>.config (IIS临时字典)
它不起作用并抛出 System.IO.FileNotFoundException因为找不到配置文件。

配置文件已复制到输出目录:始终复制(我不确定是否需要)

但是当我从 Visual Studio 测试资源管理器运行单元测试时 AppDomain.CurrentDomain.SetupInformation有路径:C:/Repository/<project>/bin/debug它有效。

我应该怎么做才能运行 ReSharper单元测试?

最佳答案

关于unit-testing - ReSharper 运行单元测试但位置错误且缺少配置文件 (ApplicationBase),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33936608/

相关文章:

unit-testing - 使用 Jasmine 进行 Angular2 AngularFire Auth 测试

nunit - TeamCity 7 上 AutoFixture 和 Moq 与 NUnit 的装配版本冲突

c# - NUnit值得学习吗?

c# - ReSharper自定义模式,从字符串中提取文本

perl - 在 Perl 测试文件中只运行一个命名的测试用例

Angular 单元测试不初始化 ag-Grid

unit-testing - NUnit - System.IO.FileNotFoundException

nunit - 如何测试两个日期是否在 NUnit 中的某个容差范围内?

c# - Ctrl+单击导航到几行之外的定义

visual-studio-2008 - Resharper 4.5 打破了我的配色方案