问题描述
我想用的xUnit作为一个测试框架。我创建的测试项目中,增加了两个的NuGet包(的xUnit和xunit.runner.visualstudio),一切的伟大工程。 Visual Studio的探索试验。
I would like to use Xunit as a test framework. I've created test project, added two nuget packages (xunit and xunit.runner.visualstudio) and everything works great. Visual Studio discover tests.
但我怎么能配置TFS 2013构建的发现,测试?什么是正确的方法呢?我发现很多的技巧,但我认为所有涉及到已下载为Visual Studio的扩展,而不是当前的NuGet包旧的测试运行。
But how can I configure TFS 2013 build to discover that tests? What's the proper way to do that? I found a lot of tips but I think all are related to old test runner which was downloaded as Visual Studio Extensions instead of the current NuGet package.
推荐答案
最后,我解决这个问题。与构建,因为的NuGet还原被称为为时已晚的xUnit没有工作。它应该在解决方案上运行的MSBuild之前调用。详细说明可在的NuGet文档网站找到。
Finally I resolve that problem. xUnit didn't work with build because NuGet restore was called too late. It should be called before running MSBuild on solution. Detailed description can be found on the Nuget Documentation website.
在应用该解决方案,它只是工作没有构建服务器上安装VS或其他任何第三方扩展。
After applying that solution it just works without installing VS or any other 3rd party extensions on build server.
这篇关于遇到问题使的NuGet版本XUnit.NET对团队建设2013的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!