Appium Tutorial for Testing Andoid and iOS Mobile Apps


#1

How to Install and Setup Appium on Windows with First Program to Get a Kick Start on Appium:

Appium is an open source and cross-platform tool that helps automate Mobile Apps testing – both Android and iOS Apps. Appium supports Native, Mobile and Hybrid Apps.

There are three types of Mobile Apps:

**Native: **Native apps built using the iOS, Android, or Windows SDKs. They are platform specific. They are built to work on a platform and/or device.

Hybrid: Hybrid apps are web applications developed using HTML, CSS, and wrapper of a native application on top of UIWebView for iOS and “webview” for Android Apps.

Mobile web apps: Mobile web apps are the apps ones accessed using mobile browsers.

Why is Appium a popular tool for automating Mobile Apps?

Appium Training is a “cross-platform tool” i.e. it allows you to write tests on multiple platforms (iOS, Android, Windows), using the same APIs. It is the most widely used tool for regression testing Mobile Apps on mobile phones and tablets.

Setting up the Appium Tool on Windows

**Prerequisites: **This is a short list of software and hardware required for automating a mobile App testing using Appium:

Your PC should have JDK, Appium Server, Eclipse, Android SDK installed
Apk: Mobile Application to be automated in our Case ContactManager.apk
Testing Device: In this case Moto G
Jars: Java-client jars and Selenium Jars.
USB driver for Testing Device: In this case Moto G
Step #1: Install the Java Development Kit (JDK)

Step #2: Set up Java Environment Variable Path

Step #3: Download and install Android SDK here and update the APIs

To update API, Open Eclipse -> Click on Window in the Eclipse Menu and -> Select Android SDK manager

Android SDK manager

Step #4: Now we need to install Appium for Windows. Go here and download Appium for Windows.

Step #5: Install Node JS from here: Node JS download

Step #6: Set the ANDROID_HOME path as well as JAVA_HOME path

Specify the path for tools and platform-tool present in Android SDK path.

Android SDK path

These folders would be present in adt-bundle-windows-x86_64-20140702\sdk

Now we need to update the Environment variable

(Note: Click on any image for enlarged view)

Update the Environment variable

Update path with tools and platform-tools (folder present in Android SDK).

The entry in Path will look as below:

C:\Program Files\nodejs;%ANDROID_HOME%\tools;%ANDROID_HOME%\platform-tools

Step #7: Access adb

Press Win+R keys combination
Type CMD. Now in CMD type ‘adb’. adb will be accessible


#2

hello
I can’t connect my phone with the Katalon.
I installed Node.js and Appium but when I click on Spy mobile or Record Mobile an error windows is shown " unable to start application on this device: Node.js is not installed".
Please if you can help me and thx.
@Azharuddin


#3

Under Katalon>> Windows Preferences>> Mobile >> What i need to set under appium directory?


#4

I can’t spy / record on android mobile. When i try to spy - Unable to capture objects Reason: WSTException Failed to execute runnable (org.eclipse.core.runtime.AssertionFailedException: null argument:). When i try to record - Unable to capture objects Reason: ExceptionException java.lang.NullPointerException


#5

Thanks for sharing
Question: can it run on android device connected with adb via ip address?
From adb I can see my ip connected device, but not from KS.


#6

Yaroslav Starshevsky said:

I can’t spy / record on android mobile. When i try to spy - Unable to capture objects Reason: WSTException Failed to execute runnable (org.eclipse.core.runtime.AssertionFailedException: null argument:). When i try to record - Unable to capture objects Reason: ExceptionException java.lang.NullPointerException

were you able to solve this?..i am experiencing the same issue using katalon 5.7.1


#7

Hi Maxwell,

What version of Appium are you running? You can find this out by running:

appium --version

from your command line.

Katalon Studio doesn’t support Appium 1.9.0 yet, so maybe that’s your issue? You could try rolling back to 1.8.1 as explained in this post to see if it helps:

https://forum.katalon.com/discussion/9410/appium-190

Hope this helps,

Chris


#8

Hello, Thanks for this valuable information. Well explained.