如何将qtRunResultsOptions.ResultsLocation设置为ALM测试集路径

huangapple go评论114阅读模式
英文:

How to set qtRunResultsOptions.ResultsLocation to an ALM test set path

问题

我正在开发一个AOM,通过.vbs文件运行我的UFT脚本。
我已经看到一些关于如何通过本地和临时路径设置结果位置的示例,但是为了我的目标,我想在ALM中的特定测试集内设置结果位置。

我已经建立了ALM连接,并成功打开了ALM中的一个脚本。

以下是我目前正在使用的代码部分,我想要修改:

' 准备RunResultsOptions对象
Set qtRunResultsOptions = CreateObject("QuickTest.RunResultsOptions") ' 创建Run Results Options对象
qtRunResultsOptions.ResultsLocation = "<TempLocation>" ' 设置临时结果位置

我想将""更改为ALM内的特定测试集路径。我想知道语法和所需参数是什么。

英文:

I'm working on an AOM to run my UFT scripts via .vbs files
I've seen some samples on how to set the Results location via local and temp path but for my goal, I want to set the Results Location on a specific Test Set inside alm.

I have already established ALM connection and manage to open a script that is inside ALM

Here's the portion of the code I am currently using and I want to modify:

&#39; Prepare the RunResultsOptions object
    Set qtRunResultsOptions = CreateObject(&quot;QuickTest.RunResultsOptions&quot;) &#39; Create the Run Results Options object
    qtRunResultsOptions.ResultsLocation = &quot;&lt;TempLocation&gt;&quot; &#39; Set a temporary results location

I want to change the "TempLocation" into a specific Test Set path inside ALM. I'm wondering what would be the syntax and parameters needed.

答案1

得分: 1

根据文档中所述,您需要使用&lt;NewLocation&gt;设置三个值TDRunNameTDTestInstanceTDTestSet

' 准备RunResultsOptions对象
Set qtRunResultsOptions = CreateObject("QuickTest.RunResultsOptions") ' 创建Run Results Options对象
qtRunResultsOptions.TDRunName = "..."
qtRunResultsOptions.TDTestInstance = "..."
qtRunResultsOptions.TDTestSet = "..."
' 上述值必须设置才能生成测试路径。
qtRunResultsOptions.ResultsLocation = "<NewLocation>"

代码未经测试
... 表示必需信息

英文:

As stated in the documentation you need to use &lt;NewLocation&gt; and set the three values TDRunName, TDTestInstance, and TDTestSet.

&#39; Prepare the RunResultsOptions object
Set qtRunResultsOptions = CreateObject(&quot;QuickTest.RunResultsOptions&quot;) &#39; Create the Run Results Options object
qtRunResultsOptions.TDRunName = &quot;...&quot;
qtRunResultsOptions.TDTestInstance = &quot;...&quot;
qtRunResultsOptions.TDTestSet = &quot;...&quot;
&#39;The above values must be set to generate a test path.
qtRunResultsOptions.ResultsLocation = &quot;&lt;NewLocation&gt;&quot;

<sup>Code is provided untested</sup>
<sup><sup>...</sup> Denotes required information</sup>

huangapple
  • 本文由 发表于 2023年7月10日 10:24:55
  • 转载请务必保留本文链接:https://go.coder-hub.com/76650345.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定