如何在WebTest中动态绑定用户定义的提取规则? [英] How to bind user defined extraction rule dynamically in WebTest?

查看:52
本文介绍了如何在WebTest中动态绑定用户定义的提取规则?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

除了将动态参数提升为webtest参数"(仅绑定会话密钥)之外,我们可以绑定fetchgriddata => grid name,执行grid action等吗?用户定义了哪些提取规则.

Apart from "Promote Dynamic parameter to webtest parameter"(which binds session key only), Can we able to bind fetchgriddata=>grid name,execute grid action,etc? for which extraction rules are user defined.

推荐答案

记录测试后,Visual Studio立即询问是否应该将动态参数提升为webtest参数" .如果不确定,通常最好回答是".记录并提升动态参数后,可以进一步自定义测试(即使其生效).其中一种工具是使用提取规则,然后在测试的后续部分中使用提取的值.

Immediately after a test is recorded, Visual Studio asks whether it should "Promote dynamic parameters to webtest parameters". If you are not sure then answering "Yes" is normally best. After recording and promoting dynamic parameters the test can be further customized (i.e. made to work). One of the tools is the use of extraction rules and then using the extracted values in later parts of the test.

将动态参数提升为Webtest参数的方法是通过创建提取规则并在需要的地方插入值.这种对动态数据的自动检测可以找到很多东西,但不能(而且我认为不能)找到所有动态数据项.因此,测试作者经常需要查找其他动态数据项.

The way that promoting dynamic parameters to webtest parameters works is by creating extraction rules and inserting the values where needed. This automated detection of dynamic data finds many things but it does not (and I think it can not) find all dynamic data items. Hence the test author often needs to find other dynamic data items.

返回问题的详细信息.在询问将动态参数提升为webtest参数" 之前,不能将提取规则添加到web测试中.因此,提取规则中的值无法自动绑定到测试中.

Back on the details of the question. You cannot add extraction rules to a web test before "Promote dynamic parameters to webtest parameters" is asked. Hence the values in your extraction rules cannot be automatically bound into the test.

另请参见

See also this page which has some more details.

这篇关于如何在WebTest中动态绑定用户定义的提取规则?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆