hp-uft - 使用 OTA 在 ALM 中删除测试集
问题描述
因此,我正在慢慢地努力使痛苦的手动过程在 ALM 中使用 OTA 自动化。我目前的斗争是删除一个测试集。它只是没有做任何事情——没有错误,没有删除,什么都没有。这就像代码行甚至不存在。虽然,它肯定在做一些事情,因为 ALM 现在工作很时髦。
我尝试了不同的方法:Delete、RemoveNode。任何建议表示赞赏。
Set qcConnection = QCutil.QCConnection
Set tsFolder = qcconnection.TestSetTreeManager.NodeById(224)
Set tstestList = tsFolder.FindTestSets("", False, "")
If tstestList is Nothing Then
print "No manual tests present", vbOK
Else
For i = 1 to tstestList.Count
Set temp = tstestList.Item(i)
if temp.TestSetFolder.father.name = strMonth then
qcconnection.TSTestFactory.RemoveItem(temp.id)
end if
Next
End If
解决方案
看来您使用了错误的工厂-您需要使用TestSetFactory
而不是TSTestFactory
推荐阅读
- html - 如何做按钮平行
- excel - 自动调用 Sub
- android - 获取列表计数然后更新列表视图中的标题
- regex - 使用 sed 捕获两个下划线之间的字符串部分
- elixir - Supervisor.restart_child/2 还是 Process.exit(pid, :kill)?
- python - 如何通过 Actionchains send_keys 像人类一样打字
- java - Java Long 数据类型在 oracle 中转换为 bigint 类型
- javascript - 推入一个新数组并过滤javascript中的冗余对象
- elasticsearch - Elasticsearch 嵌套类型有风险吗?
- sql - 从 varchar 转换为 date 不从数据库返回值