Description

After a Test Data Rule Suite has been configured with Test Data Rules and their Conditions/Actions, the suite of rules can be applied during test data generation with a downloaded Scenario, Scenario Chain, or Scenario Chain Set. 


How can test data be generated based on Test Data Rules?

Rules can be applied during test data generation in 2 ways: 

  1. Run an Test Data Rule Suite on its own with a Scenario, Scenario Chain, or Scenario Chain Set using the command line (Shown in this article).

  2. Add one or more Test Data Rule Suites to an individual Test Data Case. Then run the command line for the Test Data Case. To learn more, click here.


Note: The process of downloading required items and running the command line with GenRocket Runtime can be automated. This article will show how to do so manually.


How does it work for individual Test Data Rules in a Suite?

  1. Download the Test Data Rule Suite
  2. Download a Scenario, Scenario Chain, or Scenario Chain Set
  3. Open a Command or Terminal Window
  4. Enter and Run the Command Line for the appropriate Test Data Rule in the Suite


In This Article

This article shows how to do the following: 


Note: While this article shows how to run the Test Data Rule Suite specifically with a Scenario, the same steps are applicable for Scenario Chains and Scenario Chain Sets.


Step 1: Download the Test Data Rule Suite

Complete the following steps to download the Test Data Rule Suite to your local computer. 

  • Click on the Download (Cloud) option located on the far right of the table in the Action Column to download it to your local computer.


Step 2: Download the Scenario, Scenario Chain, or Scenario Chain Set

A Test Data Rule Suite will need to be run with one of the following:  

  • Scenario
  • Scenario Chain
  • Scenario Chain Set


These items can be downloaded from the Project Dashboard within the corresponding pane. Click on the Download (Cloud) icon to download a Scenario, Scenario Chain, or Scenario Chain Set to your local computer.



Note: To learn more about downloading Scenarios, please see:
How to Download a Scenario.


Step 3: View and Copy the Command Line in the G-Rules Dashboard

The Test Data Rule Suite and the Scenario (or Scenario Chain/Scenario Chain Set) are run using the command line shown at the bottom of the Test Data Rule Suite configuration. 


You can copy this command line within the G-Rule Dashboard and then paste it into a Command or Terminal Window to run it manually.



These values will be different depending on the name of the Test Data Rule Suite and the Scenario to be run.

  • TestDataRules.gtdr - Name of the Test Data Rule Suite
  • ScenarioName.grs - Name of the Scenario, Scenario Chain, or Scenario Chain Set.



Step 4: Paste and Edit the Command Line in a Command or Terminal Window

  • Open a Command Terminal and set the directory to where files are downloaded to your local computer.


  • Paste (or enter) the Command Line copied within the G-Rules Dashboard into the Command or Terminal Window. 


  • Replace <Scenario.grs> with the actual name of the Scenario, Scenario Chain, or Scenario Chain Set. 

  • For this example, the Scenario Name is: UserScenario.grs.


Step 5: Run the Command Line to Generate Test Data with Rules Applied

  • Press the Enter Key to execute the command line.

  • You will see All done! once the process has finished.


Note: The generated test data location will be based on the assigned Receivers. Generated data records can be output as a file, database, or another output format type.