Value From a Set Generator

Applies to ReadyAPI 3.53, last modified on May 15, 2024

The Value From a Set generator is one of the Data Generators in ReadyAPI. It generates arbitrary values. To do that, the generator takes values from a list of custom values. Using this generator, you can set the property to values from the specified list and uses them in requests and responses.

To activate the Value From a Set generator, select the desired property and set the Property Type to Value From a Set:

Value From a Set Data Generator

Click the image to enlarge it.


After you have selected the Value From a Set generator, ReadyAPI offers you to specify some additional parameters for the generated data:

Custom Values

Specifies the list containing the values that will be used to generate data. By default, this list is empty. To add a new custom value, click Add and then specify the desired value. To load the desired values from a text file, click Load and select the desired file in the Open File dialog.

To load values from a file, the file must contain one value per line.
If the Custom values list is not empty, and you click Load, the existing values will be replaced with the values loaded from the file.

To delete a value, select it on the Custom Values list and then click Remove. To delete all the custom values from the list, click Clear. To change the value order, use the Move Up and Move Down buttons.

Generation Mode

Contains a drop-down list that allows you to specify generation modes:

  • Random – Select this mode to generate a random collection of values that are specified on the Custom Values list.

  • Sequential–Default. Select this mode to generate a sequence of values that are specified on the Custom Values list. In this case, the values will be written in the same order they are presented on the list.

Duplicate Each Value … Time(s)

Specifies how many times each generated value will be duplicated. The default value of the parameter is False.

After you specify the needed parameters, you can obtain the sample values that have been generated by the engine. The values are displayed in the Sample field.

Also, you can discard all the changes you made in the generator’s parameters and restore the parameters set by default. To do that, click Set Default Values below the Sample field.

See Also

Value From a Set (%SET) Macro
Data Generator

Highlight search results