Aller au contenu principal
science

Data Generation

Data Generators produce test data for load tests. Each generator is owned by a test case and is called once per iteration, merging a set of variables into the test parameters before the iteration body runs. They live on the Data Generators tab of the Load Test panel.

remarque

Data Generators are a feature of load tests (the Data Generators tab), not a standalone test step. Each iteration consumes the next generated row/variable set.

When to Use​

  • Feeding unique or varied values (usernames, identifiers, amounts) to each virtual user
  • Driving data-driven load tests from CSV, Excel, SQL, NoSQL, or inline tables
  • Cycling through a fixed list of values across iterations

Quickest Scenario​

  1. Open the Load Test panel and select the Data Generators tab.
  2. Click Add → Random Data Generator (or Table / Variable).
  3. Configure the rules/variables and click Initialize to load the data source.
  4. Click Load Next to preview each iteration's generated variables in the Preview grid.

Common Fields​

All generators share:

FieldDescription
NameIdentifier for the generator.
Random OrderWhen enabled, values are picked at random per iteration instead of sequentially.

Generator Types​

Random Data Generator​

Generates a random value within a defined range for each rule. Add rules via Add Rule, which offers Integer Range, Double Range, or DateTime Range.

Rule fieldDescription
Variable NameThe variable that receives the generated value.
Data RangeThe configured range. Each range also supports Min Value Inclusive and Max Value Inclusive flags.
  • Integer Range — whole numbers between a minimum and maximum.
  • Double Range — decimal numbers between a minimum and maximum.
  • DateTime Range — date/time values within a range.

Table Data Generator​

Reads rows from a data source. Each column becomes a variable; each row provides one iteration's worth of data. Data is loaded once during Initialize and served sequentially or randomly from memory.

Select a Type for the data source:

TypeDescription
CSVComma-separated file.
ExcelExcel workbook.
SQLDatabase query (supports connection profiles).
NoSQLNoSQL query (supports connection profiles).
TableInline table edited in the UI.

Variable Data Generator​

Each variable defines a list of possible values (comma-separated). Per iteration a value is picked sequentially (or randomly when Random Order is on) for each variable:

FieldDescription
Variable NameThe variable to set.
Values (comma-separated)The candidate values to cycle through.

Preview​

After Initialize, the Preview grid shows the Name and Value of the variables produced for the current iteration. Load Next simulates the next generation turn.

Why​

Generators decouple test data from the test logic, so the same load test can exercise many data combinations across virtual users without cloning steps or hard-coding values.

See Also​