2. Create a Test (Legacy)

Applies to TestComplete 15.63, last modified on April 22, 2024
The information below concerns legacy mobile tests that work with mobile devices connected to the local computer. For new mobile tests, we recommend using the newer cloud-compatible approach.
  1. Open the Mobile Screen window. TestComplete records only those actions over mobile applications that you perform in this window. To open the window, click Show Mobile Screen on the Test Engine toolbar:

    Testing Xamarin.Forms applications tutorial: Show Mobile Screen window
  2. To start recording, from the TestComplete main menu, select Test > Record > Record Keyword Test:

    Testing Xamarin.Forms applications tutorial: Start recording

    After you start recording, TestComplete will automatically deploy the Orders application to the mobile device and start this application. This will happen because you enabled the Deploy to the device on start and Autorun options while creating the test project at the previous step.

  3. TestComplete will launch the tested application:

    Testing Xamarin.Forms applications tutorial: Application main page

    Click the image to enlarge it.

  4. Click the order made by Samuel Clemens. This will display the Edit item panel:

    Testing Xamarin.Forms applications tutorial: Application Edit item page

    Click the image to enlarge it.

  5. Click Edit in the top right corner of the page.

  6. In the resulting Edit Order form, clear the text Samuel Clemens in the Name text box, type Mark Twain and press Enter. Use your desktop keyboard to input text in the Mobile Screen window.

    Testing Xamarin.Forms applications tutorial: Changing of item

    Click the image to enlarge it.

  7. Click the Save button in the Edit Item panel and confirm the changes.

  8. Create a property checkpoint. It will verify that the customer list contains the new name - Mark Twain.

    • On the Recording toolbar, click Add Check. In the resulting Checkpoint wizard, click Object property:

      Testing Xamarin.Forms applications tutorial: Call the Checkpoint wizard

      Click the image to enlarge it.

    • Select the Orders list on the main page. To select text, you can –

      Press , drag the target glyph to the Orders list, and then release the mouse button.

      Click , move the mouse pointer to the Orders list, and then press the Select object shortcut (by default, SHIFT+CTRL+A).

      Testing Xamarin.Forms applications tutorial: Select the Orders list to check

      Click the image to enlarge it.

    • Click Next to continue.

    • The next page of the wizard displays a list of the selected object properties. This list includes the properties provided by TestComplete and the properties defined by the tested application. Clear the property selected by default. To view all the available properties, click More Properties:

      Testing Xamarin.Forms applications tutorial: The Checkpoint Wizard

      Click the image to enlarge it.

    • To verify the data, we will use the ItemsSource property. It provides access to individual items of tree view controls. To find this property quickly, you can use the Search text box.

    • Click the OBJ button. The table cell will expand. Find the Item element and click PAR.

    • To specify the cell holding the Mark Twain string, enter 5 in the Value box (5 is the index of the Mark Twain item in the tree view. Indexes are zero-based). Then press Enter and click the OBJ button to access the retrieved object.

    • Select the CustomerName field of the resulting object.

      Testing Xamarin.Forms applications tutorial: Selecting the property to check

      Click the image to enlarge it.

    • Click Finish.

  9. To stop recording, click Stop on the Recording toolbar.

TestComplete will stop recording and open the recorded test:

Testing Xamarin.Forms applications tutorial: The Recorded test

Prev     Next

See Also

Testing Xamarin.Forms Applications - Tutorial (Legacy)
Recording Automated Tests

Highlight search results