[英]Is there a way to associate Selenium test with an Azure DevOps test case?
What I'm aiming for is closing the loop on test coverage.我的目标是关闭测试覆盖率的循环。
My goal would be:我的目标是:
Is that even possible?这可能吗?
Check the following link:检查以下链接:
https://docs.microsoft.com/en-us/azure/devops/test/associate-automated-test-with-test-case?view=azure-devops https://docs.microsoft.com/en-us/azure/devops/test/associate-automated-test-with-test-case?view=azure-devops
Coded UI test, Selenium tests, and unit tests written using Version 1 of the MSTest framework can be associated with a test case.编码的 UI 测试、Selenium 测试和使用 MSTest 框架版本 1 编写的单元测试可以与测试用例相关联。
The process to associate an automated test with a test case is:将自动化测试与测试用例相关联的过程是:
Check this extension that I have created https://github.com/JanuszNowak/janono.ado.testcase.associate.cli .检查我创建的这个扩展https://github.com/JanuszNowak/janono.ado.testcase.associate.cli 。 It allows associating in automatic manner.它允许以自动方式关联。 So if yours selenium test are using xunit, nunit or mstest you can associate them automatically .因此,如果您的 selenium 测试使用的是 xunit、nunit 或 mstest,您可以自动关联它们。
Code sample:代码示例:
namespace ExampleTestProject
{
[TestClass]
[janono.ado.testcase.associate.Organization("janono-pub")]
public class UnitTest1
{
[TestMethod]
[janono.ado.testcase.associate.TestCase(5)] //<---
public void TestMethod1()
{
//yours test method content
//...
//
}
}
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.