Lesson 4: Create a verification point with a dataset reference

In this lesson, you create a verification point with a dataset reference to check that the price for the CD is correct in the ClassicsCD application.

About this task

What is a verification point?: A verification point captures object information and literal values from the application under test and stores it as the baseline for comparison during playback. When you play back a script, a verification point captures the object information again to compare it to the baseline and see whether any changes have occurred, either intentionally or unintentionally. Comparing the actual object information in a script to the baseline is useful for identifying possible defects.

You use a dataset reference instead of a literal value for the value that you are testing in the verification point. Using datasets with verification points gives you more flexibility to test realistic data with your test scripts.

Procedure

  1. On the Recording toolbar, click Insert Verification Point or Action Command (Insert Verification Point and Action Commands).
  2. In the Verification Point and Action wizard, drag the Object Finder (Object Finder) to $14.99, which is next to Sub-Total in the ClassicsCD application.
    The amount, $14.99, is outlined with a red border.
  3. If the Select an Action page is not displayed, click Next.
  4. On the Select an Action page, click Perform Data Verification Point to test whether the price of the CD changes.
  5. Click Next.
  6. On the Insert Verification Point Data Command page, type Price in Verification Points Name, and click Next.
  7. On the Verification Point Data page toolbar, click Convert Value to dataset Reference (Convert Value to dataset Reference) to use a dataset instead of a literal value in a verification point. (If you cannot see Convert Value to dataset Reference on the toolbar, make the page larger by dragging a corner of the page).

    The dataset Reference Converter dialog opens.

    dataset Reference Converter
  8. In dataset Variable, type Price to replace the newVariable value as the heading in the dataset.
  9. Select Add value to new record in dataset to add the Price variable to the existing dataset record that you created in the previous exercise.
  10. Click OK.
  11. Click Finish.

Place the order and close the ClassicsCD application

Procedure

  1. In the ClassicsCD application, click Place Order to place the order, and then click OK to close the message that confirms your order.
  2. Click X in the upper right corner of the ClassicsCD application to close the application.

Stop recording

Procedure

On the Recording toolbar, click Stop Recording (Stop Recording) to write all recorded information to the test script.

Results

The test script is displayed in the script editor window.

Functional Test perspective

Lesson checkpoint

About this task

In this lesson, you learned about verification points, creating a verification point while recording, and converting a value to a dataset reference.