Run Logic

1、lr_output_message()函数,其作用是将内容输出到Replay Log中:

如果输出整数型内容,应该这样写;

int x;

x=10;

lr_output_message("%d",x);

如果要输出一个字符串,那么需要这样写;

char  *x;

x="welcome to 51testing!";

lr_output_message("%s",x);

我们可以在各个action中插入lr_output_message()函数。

在vuser_init中写入以下内容:

lr_output_message(this is vuser_init)

在action中写入以下内容:

lr_output_message(“this is action“)

在end-init中写入以下内容:

lr_output_message(”this is end_init)

脚本运行的顺序和脚本的名称没有关系,而是与Run Logic的设置有关

原文地址:https://www.cnblogs.com/daixiongkun/p/7526391.html