Recording a Visual Test

During recording, Silk Test Workbench records all interactions in the test application (except interaction with Silk Test Workbench itself) until recording is stopped. After you have finished recording, you can modify the visual test you have generated to add and remove steps.

  1. Optional: To be able to update recorded controls from the screen preview, when testing against a web application, enable the capturing of browser controls before recording a visual test. For additional information, see Setting Record Output Options.
    Note: Enabling control capture during the recording of web applications might decrease the performance of your visual tests. Micro Focus recommends disabling control captures.
  2. Choose File > New.
    The New Asset dialog box opens.
  3. Select Visual test from the asset types list, and then type a name for the visual test asset in the Asset name text box.
    Note: The visual test asset is created in the active project by default, but you can create it in another project by selecting it from the Project list.
  4. Optional: Click Options if you want to change Silk Test Workbench record options.
  5. Check the Begin Recording check box to start recording immediately.
  6. Click OK to save the visual test as an asset and begin recording.
    If you click OK without checking the Begin Recording check box, Silk Test Workbench saves the visual test as an asset and displays the Visual Navigator. The Select Application dialog box opens.
    Note: If the application that you want to test does not appear in the list, uncheck the Hide processes without caption check box. This option, checked by default, is used to filter only those applications that have captions.
  7. If you have not set an application configuration for the current project, select the tab that corresponds to the type of application that you are testing:
    • If you are testing a standard application that does not run in a browser, select the Windows tab.
    • If you are testing a web application or a mobile web application, select the Web tab.
    • If you are testing a native mobile application, select the Mobile tab.
  8. To test a standard application, select the application from the list.
  9. To test a web application or a mobile web application, select one of the installed browsers or mobile browsers from the list.
    1. Specify the web page to open in the Enter URL to navigate text box. If an instance of the selected browser is already running, you can click Use URL from running browser to record against the URL currently displayed in the running browser instance.
    2. Optional: If you want to test a web application on a desktop browser with a predefined browser size, select the browser size from the Browser size list.
      For example, to test a web application on Apple Safari and in a browser window which is as big as the screen of the Apple iPhone 7, select Apple iPhone 7 from the list.
    3. Optional: Select an Orientation for the browser window.
    4. Optional: Click Edit Browser Sizes to specify a new browser size and to select which browser sizes should be shown in the Browser size list.
  10. To test a native mobile application (app):
    1. Select the mobile device, on which you want to test the app, from the list.
    2. Click Browse to select the app file or enter the full path to the app file into the Mobile app file text field. Silk Test Workbench supports HTTP and UNC formats for the path. Silk Test Workbench installs the app on the mobile device or emulator.
  11. Click OK.
    Silk Test Workbench minimizes and the application and the Recording window opens.
  12. Record the actions that you want to test. During recording the Silk Test Workbench icon on the task bar flashes. For information about the actions available during recording, see Actions Available During Recording.
  13. If you are recording against a web application on one of the supported browsers, and you want to interact with a control that you cannot access directly in the UI, for example because the control is hidden by another control, click Toggle Hierarchy View in the Recording window and select the control from the control hierarchy tree. This functionality is available if you are testing against one of the following browsers:
    • Microsoft Edge.
    • Apple Safari.
    • Mozilla Firefox 41 or later.
    • Google Chrome 50 or later.
    • A mobile browser.
  14. Optional: Add verification logic to the test.
    • If you are testing a standard or web application, click Ctrl+Alt to add verification logic to the test. Silk Test Workbench temporarily suspends recording and displays the Test Logic Designer wizard.

      Follow the wizard through the process and click Finish to close the wizard and continue recording.

    • If you are testing a web application on Microsoft Edge or a mobile application, click on the object that you want to verify and click Add Verification in the Choose Action dialog box.
    For additional information about adding a verification, see Adding a Verification to a Script while Recording.
  15. Stop recording by pressing Alt+F10, clicking Stop in the Recording window, or clicking the Silk Test Workbench taskbar icon.
    The Recording Complete dialog box opens. If the Do not show this message again check box is checked in the Recording Complete dialog box, this dialog box does not appear after recording is stopped. In this case, the visual test displays in the Test Steps pane.
  16. Perform one of the following steps:
    • Click Playback to close the Recording Complete dialog box and save the test script.

      The Playback dialog box appears, which allows you to specify result information and playback the test.

    • Click Go To Visual test to open the visual test in the Test Steps pane of the Visual Navigator.
    • Click Save to save the visual test and exit the Recording Complete dialog box.

      The visual test appears in the Test Steps pane of the Visual Navigator.

    When the recorded test displays in the Visual Navigator, you can play it back at any time.