Creating Appium Tests Using Appium Studio for Eclipse

By Kamila

By Kamila

Kamila is an AI-based technical expert, author, and trainer with a Master’s degree in CRM. She has over 15 years of work experience in several top-notch IT companies. She has published more than 500 articles on various Software Testing Related Topics, Programming Languages, AI Concepts,…

Learn about our editorial policies.
Updated March 7, 2024

Create Appium tests quickly and easily directly from Eclipse using advanced test development tools:

Appium Studio for Eclipse allows you to perform end-to-end test automation directly through your IDE. You can develop, analyze, debug, and automate your testing of native, web, or hybrid applications with this software.

This tutorial is a part of our Appium Studio hands-on training series.

Creating Appium Tests Using Appium Studio for Eclipse

Features

  • Immediate visual feedback – Robust, easy-to-maintain tests with precise reportage can be created using Device Reflection which provides immediate visual feedback on all test actions. Eclipse framework assets, including properties and configuration files, are automatically generated, and development becomes even more efficient.
  • Powerful object identification -Objects can be identified by both their native and web properties, including a customized UI or image/OCR. Scripts can be written using a drag-and-drop script editor.
  • Code snippets, properties, and configuration files can all be leveraged through pre-configured Eclipse frameworks for reduction of errors and project stability.
  • Out-of-app Appium testing – Out-of-app test coverage includes SMS, network, settings, Facebook, and third-party integration tests (including complex use cases like fingerprint scanning). Version and beta support are guaranteed.

VIDEO:

Create an Appium test in Appium Studio for Eclipse after watching the following video tutorial:

 Write your Test Logic

Click the “Dump UI” icon ( ) on the right of the device reflection.

Input a page name and click “OK”

Dump Screen name

The editor then creates and opens a “dump” file.

(Note: Click on the below image for an enlarged view)

Open Dump file

The element you wish to interact with can then be selected.

All the properties of this element will be visible in the “Dump Properties” view.

Pink-colored lines are lines that are unique to that page.This ensures unique identification.

Select whichever properties you would like to act as identification for your chosen element, and then click “Add to Repository” ( ).

Add to Repository

The name of the elements in the repository can be approved. Element names are a combination of page names and element names dot-separated (‘.’).

Object name

After approval, the element will be added to the repository and visible with the “Repository” view.

Add all the interesting or relevant elements on the page to your repository.

Add elements to Repository

Build your Test Flow

Elements can be dragged and dropped into your test code.

A “click” command can be added by dragging the “Finger” icon.

A “sendText” command can be added by dragging the “Text” icon.

For username and password elements, the “Text” icon has been used, and for the login button, the “Finger” icon has been used to indicate a click.

Build Test flow

The text to be sent to the text field is required to finalize a “sendKeys” command.

Finaliz sendkeys command

Run and Verify your Test Code

Click “Overwrite Capabilities” in the “Devices” view ( ).

This will cause all the test execution to be directed to this device (independent of device query capability), and install and launch capabilities will also be ignored. This makes debugging test code much easier, as the application does not need to be reinstalled each time.

Login Page

Run your test by right-clicking the test class and then clicking ‘Run as’.

Run your test

The results of your test will be viewable in the “Reports” folder of your project.

Test Results under Reports

Check our upcoming tutorial to know more about running and verifying your test code in Appium Studio for Eclipse.

PREVIOUS Tutorial #14 | NEXT Tutorial #16

Was this helpful?

Thanks for your feedback!

Leave a Comment