loadrunner事务判断常用方法

//判断关联到的字符串是否为空
if (strlen(lr_eval_string("{param}")) == 0);

//判断关联的字符串是否跟期望的值相同
if(strcmp(lr_eval_string("{param}"), "expected") == 0);

//判断关联的字符数组count是否为0,这种情况适合 ORD=ALL 
的关联方式
if(atoi(lr_eval_string("{param_count}")) == 0);

//根据返回的响应码是不是200
int HttpRetCode; 
HttpRetCode = web_get_int_property(HTTP_INFO_RETURN_CODE); 
if (HttpRetCode == 200) 

  

原文地址:https://www.cnblogs.com/Alexr/p/10043247.html