Recording an Object Map Item or a Locator Manually For a Visual Test

Before you begin, ensure that the application that you want to test is running.

Manually capture an object map item or a locator using the Identify Object dialog box and create a corresponding test step in a visual test.

  1. Open the visual test that you want to modify. A step that corresponds with each recorded action displays in the Test Steps pane.
  2. Click the test step in which you want to insert an object and action. The new object and action will be inserted below the selected test step.
  3. Choose Tools > Identify Object.
    The Identify Object dialog box opens.
  4. Specify the Selection mode.
    • Click – Click the object to identify the locator.
    • Hot Key – Specify this mode to capture the object using the keystroke combination specified in the Keystroke list box. Typically, you choose this mode to capture objects, such as a menu or combobox, that only appear when clicked by the user. With this mode, you select the object and then press the hot key keystroke combination to capture the locator without dismissing the object.
  5. Click Start Identify.
    If you want to capture an object map item or a locator in Google Chrome, Silk Test Workbench detects if the selected instance of Google Chrome is started with the appropriate automation parameters, and if not, Silk Test Workbench closes Google Chrome and restarts it with the automation parameters set.
  6. Optional: To bring the application under test into the appropriate state before recording a locator, click Stop Identify. The actions that you perform in the application under test are no longer recorded. To continue with the recording of a locator, click Start Identify.
  7. Position the mouse over the object that you want to record and perform one of the following steps:
    • If you use Click mode, click the object that you want to identify.
    • Press the keystroke combination to capture the object with the Hot Key mode.

      By default, the keystroke combination is Ctrl+Shift.

    Silk Test Workbench lists the related locator string in the Selected Locator text box.
  8. To refine how locators display in the Locator Details table, perform any of the following actions:
    • Hide Locator Details – To hide the Locator Details table, click this link.
    • Show object map namesCheck this check box to display object map item names in the Locator column. Object map item names associate a logical name (an alias) with a control or a window, rather than the control or window's locator. By default, object map item names are displayed. To use locators, uncheck this check box.
    • Show full locatorsCheck this check box to display the full locator name. To show only the attribute associated with the object, uncheck this check box.
    • Show propertiesCheck this check box to display any attributes and attribute values for the object selected in the Locator Details table. You can select attributes in this table to use in the locator identification. To hide the Properties subtree and display only locator details, uncheck this check box.
  9. To test that the object that displays in the Selected Locator text box is the object that you want to use, click Test. Silk Test Workbench highlights the object that corresponds with the locator in the application that you want to test.
  10. To replace the locator that you recorded, select the locator that you want to use in the Locator Details table. The new locator displays in the Selected Locator text box.
  11. To copy the object and create a test step in the visual step, click Paste. The Select Action dialog box opens.
  12. Select the action that you want the object to perform and then click OK. Silk Test Workbench adds the object and the action in a new test step to the visual test.