c# - 我能够从 ALM 获取文件夹,但不能从测试中获取 - c#
问题描述
我正在尝试阅读 ALM 中特定文件夹中的测试列表。它获取子文件夹但无法读取测试用例。没有失败,只是没有进入第二个foreach循环
static void Main(string[] args)
{
TDConnection con = createConnection("", "", "", "");
TreeManager TreeMgr = con.TreeManager;
var SubjRoot = TreeMgr.get_NodeByPath(@"Subject\Regression");
TestFactory TestFact = SubjRoot.TestFactory;
var SubjectNodeList = SubjRoot.FindChildren("", false, "");
foreach (var node in SubjectNodeList)
{
System.Console.WriteLine(node.path);
var TestFilter = TestFact.Filter;
TestFilter.Filter["TS_SUBJECT"] = @"""" + node.path + @"""";
var TestList = TestFact.NewList(TestFilter.Text);
foreach (var oTest in TestList)
{
Console.WriteLine("Test Name=" + oTest.Name + "' Test Type=" + oTest.Type);
}
}
Console.ReadKey();
}
解决方案
推荐阅读
- mysql - 依靠查询结果运行另一个nodejs mysql
- python - 用值填充熊猫系列的一部分
- python - json/python dict中出现奇怪的双反斜杠
- google-sheets - 谷歌表格使数据验证选择今天的年/月/周打开
- r - How to ignore error message in R and keep loop function going
- javascript - Problem with uploading a image via Ajax Call in php?
- html - Last-Child in nested div
- angular - 使用命名路由器出口实现多个子路由
- tensorflow - 无法在 GPU 上训练 Keras 卷积网络
- java - POJO 类在没有读/写使用的情况下被序列化