Test Data
Test data can be derived using a number of methods, each of which may be used in combination with one another:
Entered manually into the Excel-like test data file tables in MettleCI Workbench
Provided as CSV file which are imported into the relevant test data file using MettleCI Workbench
Fabricated using MettleCI Workbench's Data Fabrication capabilities (illustrated in the diagram above)
Captured from your existing unit test data sources using MettleCI's Data Interception capabilities (see below)
To create Unit Tests for your jobs you'll need to
Creating an Automated Unit Test
Unit tests can be created for individual jobs using the MettleCI workbench, or en masse (for all jobs in a project) using an automated build pipeline. When MettleCI creates a unit test, using either method, it executes the following process for each job:
- Interrogate your job definition in the DataStage repository and identify each job's source and target stages.
- Read the metadata definition of each source stage input link and target stage output link. Note that each source may supply multiple output links, and each target stage may accept multiple input links.
- Create an empty unit test data file for each source and target link, with appropriate columns and metadata.
- Read your job's list of parameters
- Create a unit test specification which provides references to all of your job's parameters as well as each newly-created unit test data file.
This animation illustrates the conceptual steps MettleCI goes through to create your Unit Test:
Multimedia | ||||||
---|---|---|---|---|---|---|
|
See how this is done from the MettleCI workbench in Creating a Unit Test.
Executing an Automated Unit Test
(Execution description here)
Multimedia | ||||||
---|---|---|---|---|---|---|
|
See how this is done from the DataStage Designer in Executing a Unit Test.
Capturing Unit Test Data
(Interception Description Here)
Multimedia | ||||||
---|---|---|---|---|---|---|
|
See how this is done from the DataStage Designer in Intercepting Unit Test Data.
Fabricating Unit Test Data
See how this is done from within the MettleCI workbench in Fabricating Unit Test Data.Install the MettleCI Workbench.
To intercept test data and run Unit Tests you'll need to Install the Unit Testing Harness.
Related FAQ Pages
Filter by label (Content by label) | ||||||||
---|---|---|---|---|---|---|---|---|
|