配置 TFS TeamBuild 以在不同的构建代理上执行不同的测试类别

发布于 2024-08-19 10:42:40 字数 560 浏览 5 评论 0原文

我试图了解如何配置 TFS Team Build 来为我的项目提供 CI 解决方案。我有一个相当常见的设置,有几个类别的单元测试。为了简单起见,假设有两个类别:

  • Exchange2003
  • Exchange2007

每个测试类别都需要在构建代理上安装特定的软件,因此我将创建两个构建代理:BuildAgentEx2003 和 BuildAgentEx2007,并具有明显的配置。

现在,当我开始 CI 构建时,我希望发生一些事情:

  1. Exchange2003 测试在 BuildAganetEx2003 上运行。
  2. Exchange2007 测试在 BuildAganetEx2007 上运行。
  3. 所有测试类别都会运行并汇总结果。

是否支持,如果支持,我将如何配置它。

PS 实际上,情况当然要复杂得多。我有一个很大的测试类别和构建代理矩阵。每个构建代理通常能够运行许多不同类别的单元测试,并且每个类别的测试都可以由一个或多个构建代理运行。要求只是每个 CI build.cat 运行一次每个类别的测试

I'm trying to understand how to configure TFS Team Build to provide a CI solution for my project. I have a fairly common setup that I have several categories of unit tests. For simplicity lets say there are two categories:

  • Exchange2003
  • Exchange2007

Each test category needs particular software to be installed on the Build Agent so I would create two Build Agents, BuildAgentEx2003 and BuildAgentEx2007, with the obvious configurations.

Now when I kick off a CI build I want a few things to happen:

  1. Exchange2003 tests to run on BuildAganetEx2003.
  2. Exchange2007 tests to run on BuildAganetEx2007.
  3. All tests categories get run and their results aggregated.

Is that supported and if so how would I configure it.

P.S. In reality of course the situation is very much more complicated. I have a large matrix of test categories and build agents. Each Build Agent would typically be capable of running many different categories of unit tests and each category of tests can be run by one or more Build Agent. The requirement being only that each category of tests be run once for each CI build.cat

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

享受孤独 2024-08-26 10:42:40

设置一个 CI 构建来构建代码库。为您需要的每个配置设置一个构建,即手动构建。

CI 构建成功后,使用 TFSBuild.exe 对每个配置排队新构建,

将原始构建号作为参数传递给排队的构建。

作为手动构建的最后一步,您可以使用 MSTest.exe 将测试结果发布到 CI 构建

Set up one CI build for building the code base. Set up one build for every configuration you need that is a manual build.

After the CI build is successful queue a new build for every configuration using TFSBuild.exe

Pass the original build number to the queued builds as a parameter.

As the last step in the manual builds you publish the test results to the CI build using MSTest.exe

┼── 2024-08-26 10:42:40

Team Build 2010 应该可以立即支持这种情况 - 尽管需要一些工作来设置构建代理并为其分配标签。但是一旦您这样做了,您应该能够使用分布式构建来构建特定构建代理并运行测试。

如果使用 Team Build 2008,情况会复杂得多。

Team Build 2010 should support this scenario out the box - although it will take some work to set up build agents and assign tags to them. But once you do that you should be able to use distributed builds to build and run tests on particular build agents.

It would be much more complicated with Team Build 2008.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文