Description

A Test Data Story (or G-Story) can be used to generate complex test data that requires multiple combinations of Scenarios, Scenario Chains, Scenario Chain Sets, and optionally Test Data Cases to generate test data. 

  • A Story may contain one or more Chapters.
  • Each Chapter must have one Component (a Scenario, Scenario Chain, or Scenario Chain Set).
  • Optionally, a Test Data Case can be applied at the Story or Chapter level.


In This Article


Step 1 - Create a Story Suite

A Project Version can have one or many Story Suites, each with its own Stories. To add a Story, you must create a Story Suite first. If one has not been created, complete the steps below: 


Step 2 - Add a Story

Each Story Suite can have multiple Stories. For simplicity, in the example below, we will only show how to add one Story.

  • Select the Story Suite within the G-Stories Dashboard.
  • Click on the Add G-Story button.


  • Enter a Name for the Story. A Story must have a unique name (CamelCase with no spaces). 


  • (Optional) Test Data Case may be selected at the Story Level and applied to the entire Story. 
  • A Test Data Case loopCount overrides the loopCount set at the Scenario level. 



  • Enter a Description (Optional) and click Save.


Step 3 - Add Chapters to a Story

A Chapter must have a unique title (CamelCase with no spaces) and contain at least one Chapter Component. 

  • Click on Add Chapter.



  • Enter a Name for the Chapter. It must be a unique name (CamelCase with no spaces). 
  • Enter a Description (Optional) and click Save.

     

Step 4 - Add Components to the Chapter

Each G-Story Chapter must have at least one Component, which can be one of the following: 

  • Scenario
  • (or) Scenario Chain
  • (or) Scenario Chain Set
  • (and optionally) Test Data Case


The loopCount of the Test Data Case will override the Scenario loopCount value. For example, if the Scenario has a loopCount of 1 and the Test Data Case has a loopCount of 10, then 10 data records will be generated. 


Complete the following steps to add components to a story: 

  • Click on the Add Component button.


  • Use one of the drop-down menus to select a Scenario, Scenario Chain, or Scenario Chain Set.  
  • A Scenario Chain has been selected for this example.  



  • (Optional) Use the drop-down menu to select a Test Data Case or G-Case. If a G-Case is applied at the Story Level, it will override any applied at the Chapter Level.

  • Click Save once finished.



Step 5 - Repeat Steps 2 through 4 for Each Story

These steps should be repeated for each Story that needs to be set up. For this example, two Stories have been set up.


Step 6 - (Optional) Set Parent/Child Relationships between Stories

Parent/Child Relationships can be set between Stories within a suite. A Child Story will automatically inherit the Chapters and Components of the Parent. 


At least two G-Stories must be present to set up Parent/Child Relationships. The Story must be located above its child to be selectable as the parent. Stories can be reordered if needed. 


  • Click on the Inherit Story (Upward Arrow) icon.



  • Select the Parent Story and click Save.



  • The Parent Story is shown in the Stories pane. 
  • The Chapters in the Parent Story are added to the Child Story. (Only one in this example - BasicInformation)



  • Each Parent Story Chapter has a toggle button that can be used to turn the Chapter on and off for test data generation

  • If toggle is off, test data will not be generated for that chapter. 


Step 7 - Generate Your Test Data

Once everything is set up, you can generate test data based on what Receivers have been assigned to the Domains. Multiple steps must be performed to generate test data:

  • Download the Required Files - This includes the Story Suite, Scenarios, Scenario Chains, Scenario Chain Sets, Case Suite, or individual Case, and any needed Configuration Files). 
    • Note: Every Component added to each Chapter must be downloaded manually unless G-Repository Server/Client is used. 

  • Copy the Command within the G-Stories Dashboard - Ensure the right Story is selected before copying the command. If you want to generate data for multiple stories at a time, you will need to set up a Test Data Epic



  • Open a Command Prompt or Terminal window. 
  • Paste the command and press the Enter Key to generate test data.


Possible Errors During Test Data Generation

If a required item for test data generation (e.g., Scenario, Case, Configuration file) has not been downloaded, is not present, or is in the wrong location, you may receive an error message similar to the ones below:


Missing Case Suite or Case

Download the Case Suite or individual Case and check that it is in the correct location.


Missing Story Suite

Download the Story Suite and check that it is in the correct location. 


Missing Scenario (or Scenario Chain/Scenario Chain Set)

Download the Scenario and check that it is in the correct location.