loadrunner参数化详解

九种参数化方法区别详解:

以登陆用户名参数化为例:
在这里插入图片描述

9种区别:

在这里插入图片描述

迭代结果:

设置迭代6次

第一种:Sequential+Each Iteration

Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172021
Action.c(66): Error: #############迭代号码是: 13026172022
Action.c(66): Error: #############迭代号码是: 13026172023
Action.c(66): Error: #############迭代号码是: 13026172019
第6次迭代从一行开始重新取值

第二种:Sequential+Each Occurrence
Action.c(66): Error: #############迭代号码是: 13026172021
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172022
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172023
Action.c(66): Error: #############迭代号码是: 13026172021

第三种:Sequential+Once
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172019

第四种:Random+Each Iteration
Action.c(66): Error: #############迭代号码是: 13026172023
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172022
Action.c(66): Error: #############迭代号码是: 13026172020

第五种:Random+Each Occurrence
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172022
Action.c(66): Error: #############迭代号码是: 13026172021
Action.c(66): Error: #############迭代号码是: 13026172020
每次迭代从文件中随机取一条数据,有可能出现重复的数据
第六种:Random+Once
出现6次
Action.c(66): Error: #############迭代号码是: 13026172023
每次都是随机取的一行数据,但是迭代的6次数据都是一致的

第七种:Unique+Each Iteration
第6次取最后一个值

Action.c(66): Error: #############迭代号码是: 13026172019
Action.c(66): Error: #############迭代号码是: 13026172020
Action.c(66): Error: #############迭代号码是: 13026172021
Action.c(66): Error: #############迭代号码是: 13026172022
Action.c(66): Error: #############迭代号码是: 13026172023
Action.c(66): Error: #############迭代号码是: 13026172023

第八种:Unique+Each Occurrence(每次出现)
在这里插入图片描述
当值不足时,可以选择以下3种方式:
1)、中断虚拟用户
2)、循环取参数中的值,返回到第一行取值
3)、取最后一行值
选择中断
Action.c(40): Error: Parameter ‘login_user’: No more unique values for this parameter in table ‘login_user.dat’ [unique range is 1-6]. The Vuser is aborted according to “When Out Of Values” policy.

第九种:Unique+Once(一次)
出现6次
Action.c(66): Error: #############迭代号码是: 13026172019

猜你喜欢

转载自blog.csdn.net/u014150715/article/details/89328457