In this Article


Required Information to Generate Data

The following information will be required to generate data: 

  1. The Object for which data needs to be generated, for example - User, Customer
  2. The properties of the Object to be populated - name, identificationNumber, phoneNumber, etc
  3. The data to be generated for each property - Swedish Names for the property name, National Id of Sweden for identificationNumber, etc.
  4. The format in which data needs to be generated - CSV, JSON or XML, etc.


How does GenRocket represent the above details?

GenRocket has a Component-based architecture. The component-based architecture of the GenRocket Test Data Automation platform is an ideal technology for defining and provisioning test data for high-volume, automated unit testing. There are five key components of GenRocket that provide total control over the nature and accuracy of test data generation.


Component

Think of it like this...

Example

Domain
(i.e Object/Entity)
A noun like a person, place, or thing.User, Account, Address
Attribute
(i.e., Object Properties)
Characteristics of a DomainA User Domain might have these: 
  • firstName
  • lastName
  • age
Generator
(i.e., generated data for a property)
Defines what data to generateNameGen, AddressGen, ListGen
Receiver
(i.e., output format)
Defines the format for the generated data.JSONFileReceiver, DelimitedFileReceiver, FixedFileReceiver
ScenarioCombines the other four key components to create a set of instructions to generate test data. Generate 10,000 records for the Domain in the specified output format. 



GenRocket Runtime

Once the Scenario is ready, it needs to be passed to GenRocket Runtime for execution and generation of data. 


The GenRocket Runtime is a secure Java program that executes the encrypted GenRocket Scenarios to generate test data in the customer’s secured, firewalled environment. It acts as an engine on your local machine and follows the instructions within the Scenario to generate the test data. 


GenRocket Runtime will need to be installed on your local computer or Server (CICD) to run Scenarios and generate your test data.




Real-time Synthetic Test-Data Generation Process:

With Test Data Automation, the process is streamlined into a 4-step process:

  1. MODEL - Import the data model
  2. DESIGN - Create a Test Data Scenario matching the needs of each test case
  3. DEPLOY - Generate test data in real-time during test operations.
  4. MANAGE - Manage multiple releases of test data projects with version control



Step 1 - Model

There are two ways the data can be modeled:

  1. Using the GenRocket Web platform - GenRocket offers multiple ways to import or create your data model, as shown below. To learn more about each available method, please click here.





  2. Using the APIs at runtime - GenRocket offers a set of Java APIs as well as REST APIs for a non-Java project to create the Scenario (Instruction Set) in real-time in the CI/CD pipeline. Please click here for more details.





Step 2 - Design

Once Modeling is done, the next step is to design; design a Test Data Case which controls how GenRocket will generate synthetic data for each test case. 


Test Data Cases can be very basic, or they can be combined into highly complex stories and epics that follow the integration of code during the Agile SDLC. Each automated test can have its own automated test data. 


There are two ways the data can be designed:

  1. Using the GenRocket Web platform - GenRocket offers a self-service platform to generate test data that accurately reflects your test case requirements. This platform provides an easy-to-use interface that allows any form of test data (positive, negative, patterns, permutations, boundary values, dynamic, load, etc.) to be designed for a given data model. For more information, click here.



  2. Using the APIs at runtime - GenRocket offers a set of Java APIs as well as REST APIs for a non-Java project to modify the Scenario (Instruction Set) as per requirement in real-time in the CI/CD pipeline. For example, changing the loop count of data in real-time.

    Please click
    here for more details.

     



Step 3 - Deploy

Once test data is designed, it’s ready for delivery and execution. GenRocket offers a collection of more than 100 Receivers that control how the data is formatted and delivered; directly into a SQL or NoSQL database, or over a Web service like REST or SOAP, or perhaps as an XML or JSON file or even an EDI transaction set.


When a Test Data Case, Story, or Epic is deployed into your test automation framework (e.g., Jenkins), it can be automatically triggered to run. Test data is generated and delivered in real-time into your automation framework. 


GenRocket runtime can be triggered from within CI/CD pipeline script using shell or batch command. Or data generation can be triggered by making a REST request to GMUS (GenRocket Multi-User Server).


Step 4 - Manage

  1. Using Web-platform - If Scenarios are being managed on a private cloud, GenRocket offers G-Repository to automatically manage the whole project artifacts on the system/server. Any change at the platform level will automatically be reflected in G-Repository managed in the Customer’s on-premise environment. G-Repository is always running to perform the essential steps required for synchronized changes:

    • Detect data model changes in the data environment
    • Update components impacted by data model changes
    • Monitor configuration changes to Test Data Projects
    • Refactor all impacted Test Data Project components
    • Synchronize the projects used by all team members
    • Log system utilization data for analytics & reporting

  2. Using Engine APIs - Using Engine APIs, Only 1 Scenario will be required that can be modified in real-time.