Storing Output Values in Variables

Using the Output Data and Output Data Properties panes, you can store output values as variables for later use or you can define verifications for the values.

  1. Invoke a method by clicking Invoke on the Workflow bar (or by right-clicking a method in the Input Data pane and selecting Invoke/Add to Test Case) and explore the output data.
  2. Select an output value node in the Output Data pane. You can store such values in variables that can be used as input values for other method calls.
  3. Select an OutputValue row in the Output Data Properties pane to display the (...) button. Click (...) to invoke the Output Value Wizard and store the value.
    Note: The Output Value Wizard can also be launched by clicking Customize on the Workflow bar, or by right-clicking an output parameter in the Output Data pane.
  4. In the Output Value Wizard, type a name for the output value variable in the Variable name text box.
  5. Define the scope of the variable. The default is Local, which means that the variable can only be used within the test case within which it has been created. Global scope means that the variable can be used within any test case. Global scope enables you to pass information between test cases.
  6. Click OK. Verifications can be executed against variables. The Verification Wizard dialog box offers two text boxes for this purpose: Variable and Array Index (which defines the array index when a variable is an array).