<分区>
[TestMethod]
[ExpectedException(typeof(FormatException))]
public void PassGodammit()
{
throw new FormatException();
}
??快把我逼疯了。
<分区>
[TestMethod]
[ExpectedException(typeof(FormatException))]
public void PassGodammit()
{
throw new FormatException();
}
??快把我逼疯了。
最佳答案
确保在从 2005 升级到 2008 后检查您的项目引用:出于某种奇怪的原因,升级向导不会升级对 Microsoft.VisualStudio.QualityTools.UnitTestFramework
的引用,并保留对版本 8.0 的引用本次大会。只需手动添加对此程序集的 v 9.0 的引用。
关于c# - 为什么此单元测试在 Visual Studio 2005 中通过但在 VS2008 中失败?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/580919/
相关文章:
C# Microsoft.Office.Interop.Excel 不会打开 Excel 窗口
git - Visual Studio-Azure 开发人员 : failed to push the branch to the remote repository
visual-studio - 非 Debug模式时在 Visual Studio 输出窗口中显示消息?
visual-studio-2008 - SSIS sql 命令没有返回任何列信息
C# DateTime 到 MySqlDateTime 转换
visual-studio - 在 Visual Studio 2013 中为 CUDA 7.0 启用语法高亮
visual-studio - Visual Studio 2010 RC 与 Visual Studio 2008 兼容吗?