0

目前我正在为 PowerBuilder v12.5 应用程序使用 RFT 试用版。在记录过程中,当我们保存一个窗口信息时,它会为变量生成一个字符串(唯一的自动生成),并使用它作为参考来存储来自其他窗口和选项卡的所有其他信息。目前 RFT 在 Object Map 中使用它作为参考,当我们回放脚本时,它会失败,因为变量的值从记录的值发生变化。我无法更改识别属性,因此在播放期间它与上述变量“业务合作伙伴 ID”不匹配。

我需要知道如何更改识别属性,以便在 playblack RFT 期间跳过此值的匹配,或者如何使此值动态化,以便在播放 RFT 时保存信息,每次都获得唯一值。

您的及时回复对我很有帮助,提前谢谢您。如果需要任何其他详细信息,请告诉我。

问候, 阿提夫·阿巴斯

4

2 回答 2

0

In cases where recognition properties of an object are dynamic , there are two approaches two handle them:

  • Convert the dynamic property value to a regular expression.
  • Convert the object itself to a dynamic test object.

You can find detail information on converting the property value to a regular expression in the below link. http://publib.boulder.ibm.com/infocenter/rtnlhelp/v6r0m0/index.jsp?topic=%2Fcom.rational.test.ft.help%2FReplExactMatchPropwithPattern.htm

Also there is a nice blog on object map of RFT: http://rftobjectmap.blogspot.in/

于 2013-10-15T06:31:32.267 回答
0

如果您想找到具有变化属性的对象,您可以考虑使用该TestObject.find方法。这允许您访问测试对象,甚至无需将它们放在对象映射中。IBM developerWorks 提供了对 find 方法的一个很好的介绍:http: //www.ibm.com/developerworks/rational/library/06/0711_nowacki_nodwell/

于 2013-10-22T09:01:08.720 回答