When designing automated tests, you may need to run the same process multiple times using different input values.
Instead of editing Variables manually for each execution, PerfecTwin provides a Data Model that allows you to manage test data in a structured and reusable way.
⚙️ How it works
A Data Model is a structured layer that connects your test data to the Variables used in Units and Scenarios.
In PerfecTwin, test data usually begins as Source Data, which can come from:
Excel files
Database tables
The Data Model acts as the bridge between this Source Data and the automation logic:
Source Data contains the raw input values.
Data Model maps those values to specific Variables used in Units.
Each column in the Data Model typically represents a Variable, and each row represents a single test case to be executed.
For example:
Source Data may contain columns like
OrderType,Customer, andMaterial.The Data Model connects these columns to the corresponding Variables in a Unit, allowing the Scenario to run repeatedly using different rows of data.
When should a Data Model be used?
A Data Model is especially useful when:
You want to execute the same scenario with multiple sets of input data.
Large volumes of test cases need to be managed efficiently.
Test data should be separated from Unit logic for better maintainability.
Real SAP data has been extracted and prepared as Source Data.
Using a Data Model keeps automation flexible, because you can change the test data without modifying the Unit itself.
Comments
0 comments
Please sign in to leave a comment.