如何确定脚本中哪些地方的内容需要进行关联,以及关联函数写入的正确位置?
1、如何确定脚本中哪些地方的内容需要进行关联,以及关联函数写入的正确位置?2、当脚本内容很庞大,如果采用录制完全相同的两份脚本,再进行脚本对比时;当需要对比差异的两份脚本函数不在同一行显示时,寻找差异点就很困难!
3、脚本中value以及差异点很多的时候,怎样确定哪些值需要进行关联或参数化,关联函数的正确写入位置该怎么确定?
以下是我列出的关Action()
{ web_submit_data("pcd!3aportal_content!2fZJGJS.ZJGJS!2fZJGJS.DESKTOP!2fZJGJSdesktop!2fframeworkPages!2fframeworkpage!2fcom.sap.portal.innerpage_2",
"Snapshot=t44.inf",
"Mode=HTML",
ITEMDATA,
"Name=NavigationTarget", "Value=navurl://7e660d57d2a96eb36a43a77aa7462bb0", ENDITEM,
"Name=RelativeNavBase", "Value=", ENDITEM,
"Name=PrevNavTarget", "Value=navurl://d4123b3f91132ad71cb14835f2ceeebf", ENDITEM,
"Name=Command", "Value=SUSPEND", ENDITEM,
"Name=SerPropString", "Value=", ENDITEM,
"Name=SerKeyString", "Value=", ENDITEM,
"Name=SerAttrKeyString", "Value=", ENDITEM,
"Name=DebugSet", "Value=", ENDITEM,
"Name=Embedded", "Value=true", ENDITEM,
"Name=SessionKeysAvailable", "Value=true", ENDITEM,
LAST);
web_url("emptyhover.html_5",
"URL=http://1.1.1.1:50000/com.sap.portal.design.urdesigndata/themes/portal/ceshi/common/emptyhover.html",
"TargetFrame=",
"Resource=0",
"RecContentType=text/html",
"Snapshot=t45.inf",
"Mode=HTML",
LAST);
web_submit_data("pcd!3aportal_content!2fZJGJS.ZJGJS!2fZJGJS.DESKTOP!2fZJGJSdesktop!2fframeworkPages!2fframeworkpage!2fcom.sap.portal.innerpage_3",
"Mode=HTML",
ITEMDATA,
"Name=NavigationTarget", "Value=navurl://7e660d57d2a96eb36a43a77aa7462bb0", ENDITEM,
"Name=RelativeNavBase", "Value=", ENDITEM,
"Name=PrevNavTarget", "Value=navurl://d4123b3f91132ad71cb14835f2ceeebf", ENDITEM,
"Name=Command", "Value=SUSPEND", ENDITEM,
"Name=SerPropString", "Value=", ENDITEM,
"Name=SerKeyString", "Value=", ENDITEM,
"Name=SerAttrKeyString", "Value=", ENDITEM,
"Name=DebugSet", "Value=", ENDITEM,
"Name=Embedded", "Value=true", ENDITEM,
"Name=SessionKeysAvailable", "Value=true", ENDITEM,
LAST);
web_submit_data("PageBuilder;jsessionid=N00RAPYKfQ8GwaBJ3C1GQ1traJAY81YhRQGaM0EA_SAP",
"Action=http://1.1.1.1:50000/webdynpro/dispatcher/sap.com/pb/PageBuilder;jsessionid=N00RAPYKfQ8GwaBJ3C1GQ1traJAY81YhRQGaM0EA_SAP",
"Snapshot=t50.inf",
"Mode=HTML",
ITEMDATA,
"Name=sap-ext-sid", "Value=8F3pRfO4C09FqFOnqjB*Sw--2EGKcbkhpcrXA6uK9cdCJg--", ENDITEM,
"Name=sap-wd-cltwndid", "Value=WID1396423864320", ENDITEM,
"Name=sap-wd-tstamp", "Value=1396423738234", ENDITEM,
"Name=PagePath", "Value=pcd:portal_content/ZJGJS.ZJGJS/ZJGJS.Role/ZJGJS.Role_JGJS_WSZZ/XmkxxlrApp", ENDITEM,
"Name=sap-wd-app-namespace", "Value=zzzz", ENDITEM,
"Name=sap-ep-version", "Value=7.11.200907072347", ENDITEM,
"Name=sap-locale", "Value=zh_CN", ENDITEM,
"Name=sap-accessibility", "Value=", ENDITEM,
"Name=sap-rtl", "Value=", ENDITEM,
"Name=sap-explanation", "Value=null", ENDITEM,
"Name=sap-cssurl", "Value=http://1.1.1.1:50000/com.sap.portal.design.urdesigndata/themes/portal/ceshi/ur/ur_ie6.css?v=7.11.3.2.1", ENDITEM,
"Name=sap-cssversion", "Value=7.11.3.2.0", ENDITEM,
"Name=sap-epcm-guid", "Value=EEDA16E655557A92BB3F4651C502B35AA40AF14F061D25218F418D1887C3D4B8", ENDITEM,
"Name=com.sap.portal.reserved.wd.pb.restart", "Value=false", ENDITEM,
"Name=DynamicParameter", "Value=", ENDITEM,
"Name=NavigationTarget", "Value=navurl://7e660d57d2a96eb36a43a77aa7462bb0", ENDITEM,
"Name=NavMode", "Value=0", ENDITEM,
"Name=DrillDownLevel", "Value=1", ENDITEM,
"Name=ExecuteLocally", "Value=true", ENDITEM,
"Name=RelativeNavBase", "Value=", ENDITEM,
"Name=PrevNavTarget", "Value=navurl://d4123b3f91132ad71cb14835f2ceeebf", ENDITEM,
LAST);
web_submit_data("pcd!3aportal_content!2fZJGJS.ZJGJS!2fZJGJS.DESKTOP!2fZJGJSdesktop!2fframeworkPages!2fframeworkpage!2fcom.sap.portal.innerpage_4",
"Method=POST",
"TargetFrame=",
"RecContentType=text/html",
"Referer=http://1.1.1.1:50000/irj/portal",
"Snapshot=t51.inf",
"Mode=HTML",
ITEMDATA,
"Name=NavigationTarget", "Value=navurl://ce6cce8cd21bf4f067702dbba9f95dd9", ENDITEM,
"Name=RelativeNavBase", "Value=", ENDITEM,
"Name=PrevNavTarget", "Value=navurl://d74a094d43dddd1964c78c1a78b72887", ENDITEM,
"Name=Command", "Value=SUSPEND", ENDITEM,
"Name=SerPropString", "Value=", ENDITEM,
"Name=SerKeyString", "Value=", ENDITEM,
"Name=SerAttrKeyString", "Value=GUSID%3A8F3pRfO4C09FqFOnqjB*Sw--2EGKcbkhpcrXA6uK9cdCJg--&1396423738234", ENDITEM,
"Name=DebugSet", "Value=", ENDITEM,
"Name=Embedded", "Value=true", ENDITEM,
"Name=SessionKeysAvailable", "Value=true", ENDITEM,
LAST);
web_submit_data("PageBuilder;jsessionid=N00RAPYKfQ8GwaBJ3C1GQ1traJAY81YhRQGaM0EA_SAP_2",
"Snapshot=t54.inf",
"Mode=HTML",
ITEMDATA,
"Name=sap-ext-sid", "Value=8F3pRfO4C09FqFOnqjB*Sw--2EGKcbkhpcrXA6uK9cdCJg--", ENDITEM,
"Name=sap-wd-cltwndid", "Value=WID1396423864320", ENDITEM,
"Name=sap-wd-tstamp", "Value=1396423740812", ENDITEM,
"Name=PagePath", "Value=pcd:portal_content/ZJGJS.ZJGJS/ZJGJS.Role/ZJGJS.Role_JGJS_WSZZ/_______", ENDITEM,
"Name=sap-wd-app-namespace", "Value=zzzz", ENDITEM,
"Name=sap-ep-version", "Value=7.11.200907072347", ENDITEM,
"Name=sap-locale", "Value=zh_CN", ENDITEM,
"Name=sap-accessibility", "Value=", ENDITEM,
"Name=sap-rtl", "Value=", ENDITEM,
"Name=sap-explanation", "Value=null", ENDITEM,
"Name=sap-cssurl", "Value=http://1.1.1.1:50000/com.sap.portal.design.urdesigndata/themes/portal/ceshi/ur/ur_ie6.css?v=7.11.3.2.1", ENDITEM,
"Name=sap-cssversion", "Value=7.11.3.2.0", ENDITEM,
"Name=sap-epcm-guid", "Value=EEDA16E655557A92BB3F4651C502B35AA40AF14F061D25218F418D1887C3D4B8", ENDITEM,
"Name=com.sap.portal.reserved.wd.pb.restart", "Value=false", ENDITEM,
"Name=DynamicParameter", "Value=", ENDITEM,
"Name=NavigationTarget", "Value=navurl://ce6cce8cd21bf4f067702dbba9f95dd9", ENDITEM,
"Name=NavMode", "Value=0", ENDITEM,
"Name=NavPathUpdate", "Value=false", ENDITEM,
"Name=RelativeNavBase", "Value=", ENDITEM,
"Name=PrevNavTarget", "Value=navurl://d74a094d43dddd1964c78c1a78b72887", ENDITEM,
LAST);
web_submit_data("PageBuilder",
"Action=http://1.1.1.1:50000/webdynpro/dispatcher/sap.com/pb/PageBuilder",
"Method=POST",
"TargetFrame=",
"RecContentType=text/html",
"Referer=http://1.1.1.1:50000/webdynpro/dispatcher/sap.com/pb/PageBuilder;jsessionid=N00RAPYKfQ8GwaBJ3C1GQ1traJAY81YhRQGaM0EA_SAP",
"Snapshot=t57.inf",
"Mode=HTML",
ITEMDATA,
"Name=sap-ext-sid", "Value=8F3pRfO4C09FqFOnqjB*Sw--2EGKcbkhpcrXA6uK9cdCJg--", ENDITEM,
"Name=sap-wd-cltwndid", "Value=WID1396423864320", ENDITEM,
"Name=sap-wd-norefresh", "Value=X", ENDITEM,
"Name=sap-wd-secure-id", "Value=74ce7830ba3811e38836286ed488c6340991812817", ENDITEM,
"Name=asyncRequest", "Value=", ENDITEM,
"Name=eventQueue", "Value=INPUTFIELDCHANGEIdaaaa.XmkcxCompView.InputFieldValue测试项目工程3018BUTTONCLICKIdaaaa.XmkcxCompView.ButtonCurrentFocusId@{\"sFocussedId\": \"aaaa.XmkcxCompView.Button\"}", ENDITEM,
LAST);
return 0;
}
于查询操作的部分脚本,希望大家讨论下哪些需要关联、关联的方法、以及关联函数的位置: 录2次代码,对比不一样的地方 可是代码太多,同样的数据,同样的操作,
使用LR自带windiff工具比较时,函数都不在同一行啊! 回放后,数据库的数据已经增加、删除、修改,达到了模拟用户操作的要求,应该就可以了 回复 4# sanshengshihl
呵呵,关键是回放不成功,有些需要关联,有些应该需要参数化啊!
两份相同操作的脚本对比起来,发现变动的数据太多了!
页:
[1]