visual-studio 导入 Visual Studio 测试项目时如何创建 vsmdi/testrunconfig 文件?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/1155743/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to create the vsmdi/testrunconfig file when importing a Visual Studio test project?
提问by Jader Dias
When I add an existing test project, my solution lacks the vsdmi and the testrunconfig files. How to create it?
添加现有测试项目时,我的解决方案缺少 vsdmi 和 testrunconfig 文件。如何创建它?
采纳答案by Nikita G.
In Visual Studio 2010 just go to Test→ Create New Test List...
在 Visual Studio 2010 中,只需转到测试→创建新的测试列表...
It will automatically add the vsdmifile and put it into the correct location, no need to add a solution item manually.
它将自动添加vsdmi文件并将其放入正确的位置,无需手动添加解决方案项。
回答by alexsome
The solution to this is a little tricky. You have to add a "New Item" to your solution, not your test project. In the "Add New Item" dialog, you can pick the "Test Run Configuration" category and then create the configuration file manually. This will also generate a vsdmi file.
解决这个问题有点棘手。您必须将“新项目”添加到您的解决方案中,而不是您的测试项目中。在“添加新项目”对话框中,您可以选择“测试运行配置”类别,然后手动创建配置文件。这也将生成一个 vsdmi 文件。
Hope this helps.
希望这可以帮助。

