Default language.

Test Execution with Automatic Rollback


At the Component element in a test scenario, there is a checkmark to make a rollback after the execution. When this is checked, Non-virtualized Test will automatically roll back the transaction. This does not include any specific commit statements in the code. When rolling back the transaction the updated data in Db2 is not available anymore to be verified. Non-virtualized Test has a solution to this. At the Component element there is another checkmark Use Post SQL. When checked, a SQL Select element appears underneath the Component element. Here a select statement can be filled in and it will be executed after the program has executed but before the roll back. In this way it is possible to verify data in Db2 even though a roll back has been performed.

Virtualizing Db2

For unit tests (not integration tests) a solution to the data establishment problem is to stub out Db2 and return Db2 data that was recorded when the test Scenario was recorded. This feature is available for unit testing in  Virtualized Test.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*