Generating test data for selected schemas
After you select multiple schemas on the Schema Canvas page, you can generate the test data of all the selected schemas simultaneously.
Before you begin
You must have completed the following tasks:
- Created a project.
- Fabricated the schemas in HCL® OneTest™ Data. See Schema creation.
- Defined properties for the fabricated schemas. See Defining properties of schemas.
- Imported schemas from the Schema Canvas page. Importing schemas into the Schema Canvas page.
- Established relationships among non-JDBC schemas. Establishing a parent-child relationship among schemas.
- Selected the schemas. See Selecting schemas.
About this task
When you select multiple schemas from the
Schema Canvas page, and one or more schemas among the
selected schemas are enabled with the pairwise property, then the following number
of records are generated for those schemas:
- If the selected schema is enabled with the pairwise property and is not referenced to any other schema, then the number of records generated are auto calculated based on the algorithm of the pairwise data generation.
- If the selected schema is enabled with the pairwise property and is
referenced to at least one parent schema, then the number of records
generated are among the least of the following values:
- The number of records of each referenced parent schema.
- The auto calculated number of records of the schema with the pairwise property as enabled.
- If the selected schema is enabled with the pairwise property and is
referenced by a child schema, which is not a pairwise enabled schema, then
the number of records generated are among the least of the following
values:
- The number of records of each parent schema.
- The value of the number of records that you enter.
Procedure
- Log in to HCL OneTest™ Server and open the team space that contains your project.
-
Open your project.
The Overview page is displayed.
-
Click
. The Data Fabrication page is displayed.
-
Click Generate data to generate the test data for the
selected schemas on the Schema Canvas page.
The Generate data dialog box is displayed.
-
Select the Connections option for the output location to
generate the test data for the JDBC-supported schemas.
Note: When you want to generate the test data for non-JDBC schemas, the options to select the output location are not displayed because the File option is considered as the default option.
- Enter the number of records that you want to generate in the Number of records field.
-
Enter a seed value in the Numeric Seed Value
field.
The seed value acts as an instance of random data that can generate the same set of data multiple times. The default seed value is blank.Note: The following table lists the maximum values for numeric seed value and number of records:
Description Maximum values Numeric seed value
8 digits (99,999,999)
Number of records
9 digits (999,999,999)
- Choose the output file format of the test data that you want to generate from the Output File Format list.
-
Click Analyze to validate the selected schemas.
If the selected schemas are validated successfully, then you can view the order of schemas execution for generating the test data. All the parent schemas are executed first followed by the child schemas.
Note: If the validation fails, it might be because of one of the following reasons:- The parent schemas of all the selected schemas are missing.
- The connection and actions of selected schemas do not exist in the project.
- Any one of the following properties of all item types of the selected
schemas are not set:
- Min size (digits) and Max size (digits) properties for each integer item type.
- Set Required property.
You must resolve the cause of failure for the successful validation of the schemas.
- Click OK.
Results
HCL® OneTest™ Data first generates the test data of the parent schema followed by the child schemas.