如果晚上月亮升起的时候,月光照到我的门口,我希望月光女神能满足我一个愿望,我想要一双人类的手。我想用我的双手把我的爱人紧紧地拥在怀中,哪怕只有一次。如果我从来没有品尝过温暖的感觉,也许我不会这样寒冷;如果我从没有感受过爱情的甜美,我也许就不会这样地痛苦。如果我没有遇到善良的佩格,如果我从来不曾离开过我的房间,我就不会知道我原来是这样的孤独.
vbs调用httpwatch
上一篇 /
下一篇 2012-10-30 12:37:47
/ 个人分类:loadrunner
51Testing软件测试网 j`xi#Z/*实现目的:使用loadrunner调用httpwatch分析web前端性能*/51Testing软件测试网0T.kX
S.P-M6\@H/n
9d.Oo7\]&rv0/*loadrunner代码*/
N5`bT_:D0
w E/Jwovr\0Action()51Testing软件测试网a'U9a7}WDY4L
{51Testing软件测试网 y`C^D&W8cC
int sysst;51Testing软件测试网A0I1]Bs%B D
lr_think_time(10);51Testing软件测试网'\/Wvs5x E5u
sysst=system("D:\vbs_demo\httpwatch.vbs");51Testing软件测试网0MM|wJs'S8o:@(Z
lr_error_message("%d",sysst);//返回0-成功,1-失败
c
|_IKu;j0TU0 return 0;51Testing软件测试网;VZ6h`:d"{(^;N"c
}51Testing软件测试网3G6X%H q)|9B L
*c.X4?3B
x3Ckn0/*vbs启用httpwatch代码*/
J&c(OHxnlsgJ+^fk0Dim filename51Testing软件测试网*xM.mM.y1k/T"qg
filename=FormatDateTime(Now,2)&FormatDateTime(Now,3)
FCt^N W0filename=Replace(filename,":","")
q6}l(gg9p_C)[
C*A0filename=Replace(filename,"-","")51Testing软件测试网5O1lu)~3c| C
filename=Replace(filename,"/","")51Testing软件测试网\F9]4E1XX+R6u
E-W%O
Dim control51Testing软件测试网C8JIlqG-B.V
Set control=CreateObject("HttpWatch.controller")51Testing软件测试网dzzOd EY{
Dim plugin
7n-\
DgJn/ga0Set plugin=control.IE.New51Testing软件测试网;]1uUfr;n3fI
plugin.Record51Testing软件测试网*`
L1f&p)T4B.e
plugin.GotoUrl(http://wwww.baidu.com)
Y4L+t3F!|"W'{p4{!Vj0control.Wait plugin, -1
D k)T.a)HhY ^0'stop recoording HTTP
q9V~O.I0plugin.stop51Testing软件测试网bsZ7h8@
'MsgBox filename
-^5SJ[b_-Y\-I0plugin.Log.Save("D:\\"&filename&".hwl")
-UG
N9ROm0}&?0'close down IE51Testing软件测试网H]0A2]s'nJ/N C1J-w ?&L
plugin.CloseBrowser
-@8v_4e}K3Bk0
!i5iT*R
x`k*q
W0Set plugin=Nothing51Testing软件测试网 ?{rJ%{Z9}-i$`l
Set control=Nothing51Testing软件测试网 \,eXIl
Y
U+[$V_/A`)rS0
收藏
举报
TAG: