All automation development and testing engineers are very well aware of ‘Selenium‘ which is the de-facto testing framework for web applications. With the changing mobile landscape, Appium is the most used framework for testing mobile apps. But is it possible to use Selenium for mobile app testing? The direct answer is ‘Not really’ but there is a long and different approach to this answer.
Appium is the most popular mobile app test framework which can be used to test all native, hybrid, and mobile web apps for iOS and Android. It is also used for mobile web testing that involves testing on real devices and real browsers. The fact is that Appium has got its roots from Selenium and it uses JSONWireProtocol to interact with iOS and Android apps using Selenium’s webdriver.
In a typical architecture, Appium is an HTTP server written in Node.js that produces and handles multiple WebDriver sessions. Appium starts tests on the device and gets commands from the main Appium server. The server is mainly the same as the Selenium server that gets HTTP requests from Selenium client libraries.
The image below is an example to show how test scripts can run on our pCloudy platform. Don’t forget to watch the video on ‘How to run Appium scripts on pCloudy‘ here.
Now that we know a bit about Selenium and Appium testing framework, let us understand the new term in Android app testing – ‘Selendroid’ which is a framework based on Selenium for automated app testing.
In other words, Selendroid is a test automation framework which can interact with multiple devices concurrently that can be tested without any modifications. It is also known as “Selenium for Android” for testing native and hybrid mobile apps and mobile web.
Let us have a look at some of the features of Selendroid:
a) It is an Open Source and is free to use
b) It supports all Android versions
c) It supports Selenium as a scripting language
d) It supports webdriver compatible languages eg: Perl, Java, C#
e) It can work on both emulators and real devices
f) It works on all native, hybrid and web-based apps
g) It is effective while executing native and cloud-based apps as it supports Selenium grid
h) It is very easy to implement.
i) With its feature called ‘Hotplugging’, it can recognize the new devices automatically.
j) It has a built-in Inspector to simplify test case development.
k) It can support various Android API versions from Android API 10 to Android API 19.
l) It can fully support parallel testing by integrating a node into Selenium grid.
Selendroid is based on the Android Instrumentation framework where tests are written using Selenium Webdriver client API, which is also called as Selenium 2 client. Hence, it can be fully integrated with existing Selenium frameworks. It is also compatible with JSON Wire Protocol.
Let us have a look at the architecture of Selendroid:
To conclude, Selenium has paved its path as a de-facto web test automation framework and Appium is providing high-level APIs that can be speedily adopted by Selenium developers, and it helps simplify the tests.
Sign up for Free Trial to test your apps on real android and ios devices. Click Here.