TFS 2017 build of ordered CodedUI unit tests doesn't give detailed results - 将所有测试视为一个测试

TFS 2017 build of ordered CodedUI unit tests doesn't give detailed results - Consider all tests as one test

我正在使用 tfs 2017 运行 CodedUI 有序单元测试。这些是我的构建步骤: 这些是我的 "Run Functional Tests" 配置: 这些是 "Publish Test Results"(我不确定它们是否正确):

已部署 TestAgent,测试 运行 正常,问题是测试结果仅显示为一个结果,我看不到每个测试的详细结果。这是我的测试结果的样子(附件是我为每次测试拍摄的屏幕截图):

我可以重现您的情况,TFS 会将这些测试视为日志中的一个测试:

DistributedTests: Total Tests : 1, Passed Tests : 0

这是一个已知问题,请参考下面link:

How to display test results of individual test in the ordered test suite in TFS Web

This is a limitation of the run functional test task. You can publish the .trx file using the "publish test results" task and it will show you all the tests but you wont know which ".orderedtest" they were associated with etc.

您需要在 Visual Studio 中打开 *.trx 文件或使用发布测试结果任务(需要检查是否继续出错)。

此外,还将测试结果页面中的结果从失败更改为全部。