google搜索 51Testing站内搜索                    软件测试门户 | 软件测试培 训 | 文章资料精选 | 软件测试论坛 | 软件测试博客 | 测试招聘求职 
打印

官网上看到的.或许对某些人有帮助.

官网上看到的.或许对某些人有帮助.


D:\Program Files\IBM\Rational\SDP\6.0\FunctionalTester\eclipse\plugins\com.rational.test.ft.wswplugin_6.1.0\rational_ft.rftcust


Problem
This technote describes the record and playback issue of HTML tag <span> and also suggests a solution for the problem.  
  
Solution
If you are using the following code to submit a form in the web page:

<span class="button" label="confirm" click="tagForm.doSubmit();"></span>

IBM® Rational® Functional Tester (RFT) cannot recognise this particular control and therefore does not click on the control during playback.

The test script recorded:

table_htmlTable_2().click(atCell(atRow(atIndex(1)), atColumn(atIndex(0))));

During playback, it cannot recognize the table_htmlTable_2_2().


To solve the problem, please refer to the following:

1. Open rational_ft.rftcust in the plugin install dir (should be: c:\program files\ibm\rational\sdp\6.0\functionaltester\eclipse\plugins\com.rational.test.ft.wswplugin_6.1.0)

2. Find the HTML proxy mapping for button:
...
<Obj L=".Proxy">
<ClassName>com.rational.test.ft.domain.html.PushbuttonProxy</ClassName>
<Replaces/>
<UsedBy>Html.INPUT.button</UsedBy>
<UsedBy>Html.INPUT.submit</UsedBy>
<UsedBy>Html.INPUT.reset</UsedBy>
<UsedBy>Html.INPUT.image</UsedBy>
<UsedBy>Html.BUTTON</UsedBy>
<UsedBy>Html.LABEL</UsedBy>
</Obj>
...

3. Add the mapping (UsedBy) for SPAN after the "BUTTON" entry and before the closing OBJ tag: <UsedBy>Html.SPAN</UsedBy>

4. Now it looks like:
<Obj L=".Proxy">
<ClassName>com.rational.test.ft.domain.html.PushbuttonProxy</ClassName>
<Replaces/>
<UsedBy>Html.INPUT.button</UsedBy>
<UsedBy>Html.INPUT.submit</UsedBy>
<UsedBy>Html.INPUT.reset</UsedBy>
<UsedBy>Html.INPUT.image</UsedBy>
<UsedBy>Html.BUTTON</UsedBy>
<UsedBy>Html.LABEL</UsedBy>
<UsedBy>Html.SPAN</UsedBy>
</Obj>

5. Make sure nothing RFT related is running (including enabled applications) because these settings are loaded in global memory so they won't apply until a full restart of RFT.

Mercury Customer Support Portal为了RFT我卸载了QTP

TOP

这样DIV/SPAN等标记就能认识了。个人觉得其实也没什么意义。除非你的开发很bt

Mercury Customer Support Portal为了RFT我卸载了QTP

TOP

不知道能行么? 不过我做的测试都能识别你说的
table_htmlTable_2().click(atCell(atRow(atIndex(1)), atColumn(atIndex(0))));


这句在我的Script里运行是没问题的

TOP

楼上,看看zhichao.su的贴,就知道为什么有这个需要了。

http://bbs.51testing.com/thread-99658-1-1.html

Mercury Customer Support Portal为了RFT我卸载了QTP

TOP

 
当前时区 GMT+8, 现在时间是 2008-9-7 03:48Copyright(C)上海博为峰软件技术有限公司 2001-2007 电话:021-64471599-8017
当您在访问网站、论坛及博客过程中遇到问题时可发送email:webmaster@51testing.com或发送论坛短信至管理员风在吹