在Visual Studio 2015中被破坏 [英] Fakes Broken in Visual Studio 2015

查看:173
本文介绍了在Visual Studio 2015中被破坏的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我拥有Visual Studio 2015 Enterprise,发现无法编译几乎所有现有的2013项目.进一步的调查表明,Visual Studio 2015无法为在Visual Studio 2013中可以使用的类型生成伪造品.

I have Visual Studio 2015 Enterprise and discovered that I cannot compile almost any of our existing 2013 projects. Further investigation reveals that Visual Studio 2015 isn't able to generate fakes for types that were fine in Visual Studio 2013.

请考虑以下步骤进行复制:

Consider the following steps to reproduce:

  • 创建一个针对.NET 4.5的单元测试项目
  • 右键单击引用"标签中的系统",然后选择添加假货组件"
  • 要消除此示例中的噪音,请编辑随后的"System.fakes"文件:
<Fakes xmlns="http://schemas.microsoft.com/fakes/2011/" Diagnostic="true">
  <Assembly Name="System" Version="4.0.0.0"/>
  <StubGeneration>
    <Clear/>
  </StubGeneration>
  <ShimGeneration>
    <Clear/>
  </ShimGeneration>  
</Fakes>

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆