Beruflich Dokumente
Kultur Dokumente
Introduction
Without TestBench, developers have to manually verify test results, or use tools that
are limited to the playing of scripts and the automatic comparison of screens.
Library If using the IBM iSeries as the server this is the library in
which the TestBench application is stored and should be left as the
default TB_xPO. For SQL, Oracle and Access this is the name of
the TestBench database.
Product Registration
Without any product registration, TestBench-PC simply provides a view of the product structure
which includes Projects and Test Cases, and allows these placeholders to be defined and
modified. However, in order to create scripts, run tests and manage the database, one or all of
the following products should be registered.
TestDrive-Gold – Record and play back scripts over Windows and Web applications.
• TestDrive-Assist – Make use of the manual testing functionality to document screen and
database test results.
• TestBench for Oracle – Manage an Oracle database by extracting test data and rolling
back changes made as a result of testing and run integrated tests which provide database
and log information in addition to the visual layer testing.
Right click on the single grey box in the top left of the Edit Variable Data window
to begin creating variable data fields and transactions for new Variable Data Sets.
Column Options
Data Rules represent a key component of TestBench as they allow the database
effects of a test run to be proactively checked without requiring further action by
the user. Data Rules are available both on the iSeries and on Oracle if a valid
TestBench for Oracle license exists. However, if the iSeries is the server then
Data Rules must be defined and their results viewed on the server (see the Testing
chapter of the TestBench User Guide for more information), only TestBench for
Oracle Data Rules can be managed using TestBench-PC.
In TestBench for Oracle, Data Rules can be defined at the Project level or for an
individual Test Case. If defined at a Project level then they will be automatically
applied to all Test Cases, unless the option on the Test Case is set to exclude them.
Data Rules can be defined for any table and there is no limit to the number of
Data Rules that can be defined for a single table.
Data Rules can be used in all aspects of testing, but they are often constructed by
Systems Analysts, Database Designers and Technical staff. However, their power
to validate can be maximised if they are also applied during later phases of testing
such as regression or UAT.
How Data Rules Work
A data rule consists of two main components - WHEN rules (selection conditions) and
TEST rules (rules for validating data). The WHEN portion of the rule is used to identify
which rows the TEST portion can be applied to. This means that different rules can be
set up for data in different conditions, for example one rule for Invoices and another for
Credit Notes. If there are no WHEN conditions, the rule will apply to all rows.
At the end of each test, Data Rules are applied and checked against the database
effects captured from the test and any discrepancies are reported as Warnings.
The full details of the discrepancy can be viewed side by side with the Data Rule in
TestBench-PC results.
When a valid TestBench for Oracle license exists, an additional Test Environments
tab is available in TestBench-PC. Test Environments consist of a list of Schemas
which contain the test data for an application. If a Test Environment is defined for a
Test Case, when any scripts stored within that Test Case are played back with the
‘Activate Test_IT’ option checked, results in the form of database effects and data
rules are reported.
Test Environments also enable data that has been changed by a test to be rolled
back to a previous state, thus allowing you to run a program many times knowing
that the starting point of all the tables will be consistent. This capability is essential if
you are using a ‘record and playback’ tool such as TestDrive-Gold to exercise your
interactive programs, as without a data starting point identical to that when the script
was created, it is inevitable that many differences will be found during the execution
of the script. This can be done even if TestBench is not being used to initiate tests
via Test Cases and Scripts, but when testing is being performed in your application
directly.
Checkpoints
A checkpoint consists simply of a description which can be changed in edit mode
at any time without affecting the operation of the Checkpoint.
Launch Files
Launch files are used for two purposes. Firstly they support integration
with Mercury Quality Center and enable you to launch a particular Script, Map or
set of Results without going through TestBench-PC. To use the file in Quality Center
simply add it as an attachment as you would any other PC file. To launch outside of
Quality Center simply right click the file and select ‘Launch’. Secondly they enable
complete information to be specified which facilitates the fully automated execution
of a Script or Action Map in unattended mode. This means that a scheduler can be
used to launch a series of tests at a specified date and time.
Maintenance
Launch files of the first type can be created for an entire Project or Test Case by
right clicking the Project or Test Case in TestBench-PC and selecting the ‘Create
Launch File’ option. The launch files are created in a folder called My Original
Software\Launch Files in the MyDocuments folder on the PC and have the
extension .TBC. Files of both types can be created for individual components by
either right clicking a Script or Action Map in TestBench-PC, or by selecting the
option from the File menu when the Script or Action Map is open. The following
wizard is then used to specify the required parameters.
Test Case Results