Used Values and ActionModes
During test execution, Tosca Commanderâ„¢ can transfer values to the test object to be verified or read out. This can be carried out with the aid of the ActionModes Input, Verify, Buffer and Output .
The values that have been entered into the TestStep are displayed in the Value column in the ExecutionLists after test execution. If, for instance, a dynamic value was used, the actually used value is shown in the Used value column.
What are used values good for?
-
Dynamic expressions:
For recording the value that is actually used in dynamic expressions.
-
Data sources:
For adding used values to data sources, such as Test data management, TestCase-Design or Excel.
-
Synchronizing values:
For synchronizing used values in the TestCase after test execution.
The results of ExecutionEntries as well as the used values can be synchronized when using the Quality Center Integration AddIn.
Which settings must be taken into account?
The ActionModes Input and Output are enabled by default. The setting Log UsedValue for all Actions must be enabled for the used value to be displayed for all ActionModes.
For the ActionModes Input, Buffer and Verify, all table steering values can be displayed in the Used value column: ActionMode, column, value and row. This option must be enabled via the setting Fill Used Value.
The Used value is always displayed for table controls, regardless of whether the TestCase was executed successfully. Only successful test results are displayed for simple controls if the setting Report Successful Execution of is enabled for TestStepValues.
Where can I find the Used value column?
After test execution, the used values are displayed in the Used value column of the corresponding ExecutionList for a specific TestStepValue. This column is hidden by default and can be shown via the Add or remove columns.
Screenshot
Transferring used values to the TestCase
Values, which have been read out into the Used value column by using the ActionMode Output, can be copied to the TestCase. This functionality can be enabled in the context menu of ExecutionLists or ExecutionEntries via the option Transfer results. If this is desired, the ActionMode of TestStepValues in the following dialog can be automatically set to Verify.
Transferring used values to the data source
TestCases with data from a data source - TemplateInstances - are created during dynamic test execution. Used values that are actually outputted by the test object can be added to these data sources. The functionality of used values is used to accomplish this. These values can be transferred to the data source after test execution. This is carried out by selecting the option Update Datasource from the context menu of a synchronized ExecutionEntryFolder.
Please note that the ActionMode of the values of the TestStepValue to be transferred is set to Output in the TemplateInstance. |
Example - dynamic expressions
The Tosca HTML sample application will be used for this example. A value from the buffer variable First name will be used as the TestStepValue with the same name. The date of birth is generated by a dynamic expression.
Using dynamic values
Example - Output
The Tosca HTML sample application will be used for this example. TestCases are created and a TestCase-Design Sheet is used as a data source. The sample application will be tested with different kinds of data and the result of individual TestCases will be transferred to the data source.
A detailed description of the options discussed here can be found in the chapters that are linked to them. |
-
First, a TestCase-Design Template is created. An excerpt of the quote - the last page of the application - is shown in the following screenshot.
Quote table in TestCase-Design
-
The next step is to construct a TestCase that is then changed into a TestCase template and is linked to the TestCase-Design Sheet as a data source.
-
The values of each quote should be copied from the insurance calculator and transferred into the data source. The ActionMode Output is used for the TestSteps for the quote in the template.
TestSteps for calculating premium
-
The TestCase template can now be instantiated in order to execute the resulting TestCases.
The used values are read during test execution, and can be seen in an ExecutionList in the Used value column once the test execution has finished.
Used value column
-
As an optional extra step, the values that are output can be copied into the data source using the context menu entry Update Data source.
Updating the data source
If desired, these values can now be transferred to the TemplateInstance .
Transferring results
Checklist
Are all required settings specified correctly? | |
Are the dynamic expressions that are being used correctly formulated? | |
Have you used the Column Chooser to show the Used Value column? |