Skip to content

Appium Tutorials

Appium provides a powerful way to automate mobile applications across Android and iOS devices. With the setup of Appium and writing simple scripts, you can begin testing your mobile applications. Let’s first understand the Appium tool.

What is Appium?

Appium is an open-source, cross-platform tool for automating mobile applications on iOS and Android platforms. It allows you to write tests using various programming languages such as Java, Python, Ruby, JavaScript, and C#. Appium can be used to automate native, mobile web, and hybrid applications on iOS/Android and Windows.

 

Appium Tutorials

Appium Architecture

Appium automation supports Native, Hybrid, and Mobile Web application testing, and you can execute Appium scripts on simulators, emulators, and real physical mobile devices.

Appium Pre-requisites

Before you begin with Appium, you need to have the following set up:

  • Java – Appium is written in Java, so you need to have Java installed on your machine.
  • Node.js – Appium is a Node.js based application. Install it from the official website.
  • Android Studio / Xcode – You need Android Studio for Android apps and Xcode for iOS apps to run Appium tests.
  • Appium – You need to install the Appium server. Install Appium Desktop server

Appium Maven dependency

Add Appium Dependencies to the Maven project.

In your pom.xml file, add the following Appium dependencies:
Modify the version to the latest.

<dependency>
<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>7.5.1</version>
</dependency>

Mobile Automation Setup

Learn how to set up a Mobile automation environment. Install the Appium Studio Eclipse plugin.  Appium Studio allows you to easily develop, execute, analyze, and debug your tests on remote physical devices.

Android Virtual Device

Learn how to create an Android virtual device using the AVD Manager. (AVD stands for Android Virtual Device). Virtual devices allow you to test your application without having to own any physical devices.

Appium Commands and Concepts

Some important Appium commands are as follows:

DesiredCapabilities: Used to define the settings for the Appium server, like the app’s platform and version.
AppiumDriver: The base class to interact with mobile devices. It can be specialized as AndroidDriver or IOSDriver depending on the platform.
MobileElement: A class that represents elements in the app and allows actions like click(), sendKeys(), and getText().

Run Appium Tests

Run Appium Tests on a Virtual Machine

We can test mobile applications using real devices or using simulators emulators and cloud devices.

Appium Inspector

Appium inspector is an inspector GUI tool to inspect elements that help in the creation, execution, and debugging of Appium tests.

Cloud Tests

Cloud Testing Platforms.Running Appium test on a Cloud Device

Sample Cloud Test

 

Appium 2.0