gpt4 book ai didi

MSTest 在 .NET Core RC2 上没有 xml 输出

转载 作者:行者123 更新时间:2023-12-04 23:40:52 27 4
gpt4 key购买 nike

我的目标是 dotnet-test-mstest": "1.0.1-preview在我的测试项目中的 dotnet core rc2 上。

编辑:
好的。我的目标是桌面.NET。但这不应该有任何区别。

项目.json

{
"version": "1.0.0-*",

"testRunner": "mstest",

"dependencies": {
"Betgame": "1.0.0-*",
"dotnet-test-mstest": "1.0.1-preview",
"MSTest.TestAdapter": "1.0.0-preview",
"MSTest.TestFramework": "1.0.0-preview",
"NETStandard.Library": "1.5.0-rc2-24027"
},

"frameworks": {
"net461": { }
}
}

运行时输出 dotnet test看起来相当不错!

enter image description here

如何在构建过程中将输出作为 xml 文件进行处理?有任何想法吗?还是只是还不支持?

到目前为止,我尝试了 dotnet test -xml test-results.xml但没有产生输出。

最佳答案

感谢您试用 MSTest 版本。
请使用以下内容生成 trx 报告(xml 文件):

vstest.console.exe project.json /UseVsixExtensions:true /logger:trx

报告在 TestResults 文件夹中生成。

关于MSTest 在 .NET Core RC2 上没有 xml 输出,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37983495/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com