Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/apache-kafka/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 为什么NUnit测试适配器在转换功能时给我FileNotFound异常?_C#_Visual Studio 2015_Nunit_Specflow - Fatal编程技术网

C# 为什么NUnit测试适配器在转换功能时给我FileNotFound异常?

C# 为什么NUnit测试适配器在转换功能时给我FileNotFound异常?,c#,visual-studio-2015,nunit,specflow,C#,Visual Studio 2015,Nunit,Specflow,我正在使用VisualStudio 2015。我已经安装了NUnit3(3.5)、NUnit3TestAdapter(3.6还安装了VS扩展)、SpecFlow(2.1.0)和相应的Selenium驱动程序NuGet包 我有一个解决方案,其中有两个项目。一个项目可以完美地构建并发现其中的特性测试。但是我的另一个项目构建得非常完美,测试没有被发现。如果转到测试输出,则会出现以下FileNotFound/转换错误: ------ Discover test started ------ NUnit

我正在使用VisualStudio 2015。我已经安装了NUnit3(3.5)、NUnit3TestAdapter(3.6还安装了VS扩展)、SpecFlow(2.1.0)和相应的Selenium驱动程序NuGet包

我有一个解决方案,其中有两个项目。一个项目可以完美地构建并发现其中的特性测试。但是我的另一个项目构建得非常完美,测试没有被发现。如果转到测试输出,则会出现以下FileNotFound/转换错误:

------ Discover test started ------
NUnit Adapter 3.6.1.0: Test discovery starting
Exception System.IO.FileNotFoundException, Exception converting Calculations.Calculations.Feature.SendANewQuote.SendANewQuote("18-1980","150","Yearly","1337","RiskProfile","email@email.com",System.String[])
Could not find file 'PathToCalculations\bin\Config\Calculations.pdb'.
我在该项目中的所有其他测试都是一样的。我的另一个项目没有这个问题,但是所有的引用和包都是一样的


如何修复此错误,使NUnit测试适配器能够发挥其神奇作用?

最近适配器或VS发生了更改,这意味着在使用适配器时必须生成pdb文件。这里有一个有待研究的问题:

听起来您可能没有为“计算”项目生成pdb。您可以通过进入“项目设置”>“构建”>“高级”,并从“调试信息”下拉列表中选择“完整”或“仅pdb”


谢谢!这解决了我的问题!