NUnit显式测试在Visual Studio Team Services构建输出中记录为失败 [英] NUnit Explicit tests logged as Failed in Visual Studio Team Services build output

查看:76
本文介绍了NUnit显式测试在Visual Studio Team Services构建输出中记录为失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Visual Studio Team Services(VSTS)构建服务器上执行NUnit测试时,测试标记为  Explicit  是
根据控制台输出正确跳过:

  2016-12-06T10:00: 47.2789724Z信息:NUnit适配器3.6.0.0:测试执行完成
2016-12-06T10:00:47.2789724Z
2016-12-06T10:00:47.5128672Z结果文件:C:\\ \\1\s\\ TestResults\buildguest_TASKAGENT5-0027 2016-12-06 09_59_48.trx
2016-12-06T10:00:47.5158684Z
2016-12-06T10:00:47.5158684Z附件:
2016- 12-06T10:00:47.5168676ZC:\\\\\\\ TestResults; \\\\\\\\\\\\\\\\\ -12-06T10:00:47.5168676Z
2016-12-06T10:00:47.5168676Z总测试:76。通过:62。失败:0。跳过:0。
2016-12-06T10: 00:47.5168676Z测试运行成功。
2016-12-06T10:00:47.5178694Z测试执行时间:1.1636分钟


但是,所有显式测试都标记为  失败 在测试
记录  trx  这样的文件:

 < UnitTestResult execution ID = QUOT; a5898e64-e18b-497c-aaa3-6f0b3c188154" testId = QUOT; 34822bf0-4fc5-43dd-9d33-5979bab83594"测试名=" TestInspectorConstraint" COMPUTERNAME = QUOT; TASKAGENT5-0027"持续时间=" 00:00:00.0010000"开始时间= QUOT; 2016-12-06T09:59:50.0000000 + 00:00" ENDTIME = QUOT; 2016-12-06T09:59:50.0000000 + 00:00" testType = QUOT; 13cdc9d9-ddb5-4fa4-a97d-d965ccfc6d4b"结果= QUOT;失败" testListId = QUOT; 8c84fa94-04c1-424b-9868-57a2d4851a1d" relativeResultsDirectory = QUOT; a5898e64-e18b-497c-aaa3-6f0b3c188154" /> 


我正在使用NUnit 3.5和3.6.0 NUnitAdapter。



< p style ="color:#333333; font-size:14px; margin-bottom:0px!important">我向NUnit适配器团队提出了同样的问题,但它被拒绝,因为没有任何问题需要修复:  https:/ /github.com/nunit/nunit3-vs-adapter/issues/278#event-883510711

解决方案

你好,


我们正在检查查询,很快就会回复你。


为此带来的不便深表歉意并感谢您在这件事上的时间和耐心。< /温泉n>


问候,




When NUnit tests are executed on Visual Studio Team Services (VSTS) build server, tests marked as Explicit are correctly skipped as per console output:

2016-12-06T10:00:47.2789724Z Information: NUnit Adapter 3.6.0.0: Test execution complete
2016-12-06T10:00:47.2789724Z 
2016-12-06T10:00:47.5128672Z Results File: C:\a\1\s\TestResults\buildguest_TASKAGENT5-0027 2016-12-06 09_59_48.trx
2016-12-06T10:00:47.5158684Z 
2016-12-06T10:00:47.5158684Z Attachments:
2016-12-06T10:00:47.5168676Z   C:\a\1\s\TestResults\f3d40ef8-75d5-4756-b1c5-e6338daf9b3c\buildguest_TASKAGENT5-0027 2016-12-06 09_59_37.coverage
2016-12-06T10:00:47.5168676Z 
2016-12-06T10:00:47.5168676Z Total tests: 76. Passed: 62. Failed: 0. Skipped: 0.
2016-12-06T10:00:47.5168676Z Test Run Successful.
2016-12-06T10:00:47.5178694Z Test execution time: 1.1636 Minutes

However, all explicit tests are marked as Failed in test record trx file like this:

<UnitTestResult executionId="a5898e64-e18b-497c-aaa3-6f0b3c188154" testId="34822bf0-4fc5-43dd-9d33-5979bab83594" testName="TestInspectorConstraint" computerName="TASKAGENT5-0027" duration="00:00:00.0010000" startTime="2016-12-06T09:59:50.0000000+00:00" endTime="2016-12-06T09:59:50.0000000+00:00" testType="13cdc9d9-ddb5-4fa4-a97d-d965ccfc6d4b" outcome="Failed" testListId="8c84fa94-04c1-424b-9868-57a2d4851a1d" relativeResultsDirectory="a5898e64-e18b-497c-aaa3-6f0b3c188154" />

I am using NUnit 3.5 and 3.6.0 NUnitAdapter.

I raised the same issue with NUnit adapter team but it got rejected as nothing to be fixed by them: https://github.com/nunit/nunit3-vs-adapter/issues/278#event-883510711

解决方案

Hello,

We are checking on the query and would get back to you soon on this.

Apologize for the inconvenience and appreciate your time and patience in this matter.

Regards,



这篇关于NUnit显式测试在Visual Studio Team Services构建输出中记录为失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆