< Previous | Next >

Lesson 4: Recording a test

In this lesson you learn how to record your actions on an iOS device and then use the recording to generate a test.
This lesson continues where Lesson 2 and Lesson 3 leave off. (Remember, Lesson 2 is intended for users who have access to the Xcode project that contains the UICatalog application. Lesson 3 is intended for users who do not have access to the Xcode project.) Before you start recording, verify that the iOS device is connected to the test workbench and that the AUT is installed on the iOS device as described in Lesson 1: Setting up the test environment.

You create a mobile test by recording your actions in an app on an iOS device. At the end of the recording session, you close the app and the recording is uploaded to the test workbench, where it is used to generate a test.

To record a test:

  1. On the mobile device, open the Safari or Chrome browser and connect to the test workbench as described in Lesson 1: Setting up the test environment. You can connect either by typing the Workbench URL or by using a QR code scanner to scan in the Workbench URL.

    The mobile test client opens in the browser:

    Mobile test client

  2. Tap Manage applications to display a list of instrumented apps that are installed on the device. For this lesson, the UICatalog app will be used.

    UICatalog app

  3. Tap the application to test, for example UICatalog.

  4. Tap Record to start recording your actions.

    All of your actions on the device and responses from the app are recorded, The Mobile devices editor in the test workbench shows that a recording is taking place on the device.

  5. To end the recording, tap the Home button on the iOS device.

    The recording is uploaded to the test workbench and displayed in the Test Navigator under Mobile Incoming Recordings with a name and a timestamp. Depending on the size of the recording, the upload might take a few seconds to several minutes.

    Mobile incoming recording

  6. In the Test Navigator view, click the link in the message that says There is a new incoming recording. Click here to generate a test. Alternatively, expand Mobile Incoming Recordings, right-click a recording, and select Generate Test.

    The New Test from Incoming Recordings window opens.

  7. Select a parent folder and a name for the new test and click Next. If necessary, click the down arrow to create a new Test Workbench project folder.
  8. In the Select incoming recording page, select the incoming recordings for UICatalog and click Finish.

    Select incoming recordings

  9. When test generation is complete, click Open test.

    The generated test opens in the Test Contents section of the test editor, as shown in the following example:

    Test script recording

  10. You can also view the test on the iOS device.
    1. From a browser on the device, display the AUT in the list of Managed Applications, as you did in Step 2.
    2. Tap the AUT to view the list of recorded tests.
    3. Tap one of the tests to view information about the test.
    4. Tap Open Steps to view the steps in the recorded test, as shown in the following figure:

      Open Steps

Lesson checkpoint

In this lesson you learned how to record a test on an iOS device and save it to the test workbench.
You learned how to do the following tasks:
  • View the list of applications that are installed on the device
  • Start and finish a recording
  • Generate a test from the recording
  • View the recorded test in the test workbench and on the device
< Previous | Next >

Feedback