Manage test data

This chapter explains the concept of test data management and provides you with information to use Tricentis Test Automation for SAP Test Data Service.

Why test data management?

Test data management is about identifying the right test data for the execution of your tests. The identification of the appropriate test data is the most time-consuming and resource-intensive challenge faced by testers today. Test automation and continuous testing, required to meet the promise of Agile and DevOps, make it even harder.

The Tricentis Test Automation for SAP Test Data Serviceaddresses these challenges and provides you with a central place to:

  • Register your test data

  • Use the right data in your tests

  • Track the state of test data over its entire life cycle

  • Manage shared data

Register your test data

Before you can use test data in your tests you need to register the items that you want to use in Tricentis Test Automation for SAP Test Data Service. Since you will later want to search for items, you need to register them for a specific type. You also want to specify a list of attributes that you want to use to find the item.

These attributes also allow you to track the state of an item, e.g. if it is a new item or if an item was already modified.

Do this with the TestData - Create & provide new item Module and insert only the data you need to find the right item later.. For information on how to create new items, see chapter "TestData - Create & provide new item".

Use data in your test

Of course you want to use test data in your tests. You can search items by using the TestData - Find & provide item Module. For information on how to find items, see chapter "TestData - Find & provide item".

Use external test data

Track the state of the test data over its entire life cycle

After finding your item, update the status and add additional attributes to the item. This helps you to prepare your data for the next step in your test. For example, a car with specific license plate can only be used once, or a certeain person can only be created once. For information on updating your items, see chapter "TestData - Update item".

You can use the TestData Modules in the Standard subset to keep track of changes, for example, an ID that you will need in the next step. You can also use this to rebuild a state to make sure the next step in your end-to-end test uses the correct item. Another way to change the item type is to use the TestData - move item to TDS type Module. This Module allows you to reduce the lifetime of items, for instance. If your use case is a car insurance, you can change the item type from "new car" to "insured car" to "damaged car".

At the end of your tests, you can delete an item if you no longer need to track its status. You can do so by using the TestData - Delete item Module. You can also delete all items of a certain type (see chapter "TestData - Delete item") or delete all items in your repository (see chapter "TestData - Expert module"). Use these carefully as you cannot recover this data.

 

Test data process chains

Manage shared data

Sometimes you have to share the test data you need with other test cases. For example, a list of available credit cards that can be used several times as payment options. Exclusive access to an item, i.e. only one test case can use this item, can lead to failed tests in a distributed environment. Use the ReadOnly property of the TestData - Expert Module to get the data in this case (see chapter "TestData - Expert module").