且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Visual Studio/mstest如何识别测试项目?

更新时间:2023-11-30 17:58:46

在项目文件中,有一个名为ProjectTypeGuids的XML元素,其中包含一些表示测试项目的GUID.示例如下.

In the project file, there's an XML element with the name ProjectTypeGuids, that holds a few GUIDs that denote test project. Example as follows.

<Project>
  <PropertyGroup>
    <ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
  </PropertyGroup>
</Project>

以下是Visual Studio 2010的已知项目类型GUID的列表: http: //onlinecoder.blogspot.com/2009/09/visual-studio-projects-project-type.html

Here's a list of known project type GUIDs for Visual Studio 2010: http://onlinecoder.blogspot.com/2009/09/visual-studio-projects-project-type.html

在上面的示例中,它显示了该项目的类型为 Test Windows(C#).

In the example above, it shows the project to be of type Test and Windows (C#).