Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
1.
Executive Summary............................................................................................. 2
2.
3.
Tools Shortlisted................................................................................................... 3
Selendroid......................................................................................................... 3
Appium.............................................................................................................. 3
4.
Proof-Of-Concept Details...................................................................................... 3
Types of Application.......................................................................................... 3
Control Covered................................................................................................ 4
Gestured Covered............................................................................................. 4
Features Covered.............................................................................................. 4
5.
Selendroid............................................................................................................ 5
Architecture...................................................................................................... 5
Key Features..................................................................................................... 5
Limitation.......................................................................................................... 5
6.
Appium................................................................................................................. 6
Architecture...................................................................................................... 6
Key Features..................................................................................................... 7
Limitations........................................................................................................ 7
7.
Challenges Faced................................................................................................. 8
8.
Go Forward Plan................................................................................................... 8
9.
Installation Guide................................................................................................. 9
Prerequisites Installation................................................................................... 9
10.
Change History............................................................................................... 10
1 | Page
1. Executive Summary
There is an urgent need within the organization to build competency on Mobile
Automation. With this objective in mind the team decided to do a come up with an
approach that could help us to bring mobile automation in our list of capabilities and
also identified the areas that we need to focus on keeping the long term goal in
mind which is having all the tools and technique required to keep win projects in
the Mobile Automation platform.
The tools selected and ProofOf -Concepts developed is the first step in this
direction. Currently the tool list is small and the ProofOf Concepts are also limited.
But we are working on increasing this list.
After successfully achieving the first milestone the team is now focusing on the go
forward plan.
2 | Page
3. Tools Shortlisted
After studying the Mobile ecosystem the team has shortlisted two tools open source
tools Selendroid and Appium for the near short term.
Both these tools are currently market leaders when it comes to the open source
tools are concerned and together give the right kind of coverage when it comes to
Android and iOS devices.
Selendroid
Selendroid is mobile automation framework that allows you to test multi type
mobile applications on Android. i.e. Native and Hybrid app, mobile web
applications. Selendroid can be used on both, real devices and emulators.
Appium
Appium is an automated testing tool based on selenium that supports tests on
iOS and Android both. Similar to Selendroid, Appium also allows native, hybrid
and web application testing and supports automation test on real devices as well
as on emulator.
4. Proof-Of-Concept Details
The logic behind these Proof-Of-Concepts was to quickly develop small scripts that
help us to understand the following:
1.
2.
3.
4.
Support for Native and Hybrid applications and browser based applications
Support for various input controls on applications and browsers
Support for devices and Simulators
Identifying limitations
Types of Application
1. Native
2. Hybrid
3. Browser based
3 | Page
Control Covered
Text Boxes
Buttons
Links
Images
Calendar Controls
Dropdowns
Radio Buttons
Gestured Covered
1. Flick
This action is also known as swipe. We can flick the screen horizontally by
providing offset for X axis and vertically by providing offset for Y axis.
2. Single Tap
Single tap works as Click.
3. Double Tap
DoubleTap is same as Double Click. Function doubleClick() can also be
used to perform this action.
4. Highlight Elements on WEBVIEWs
5. Multi Touch Event
Creating a group of touch events and execute them at same time which
creates a multi touch event. Multi touch events usually performed on
Native Apps.
6. Long press an element
7. Hide Keyboard.
Features Covered
1. Change WEBVIEW
In Hybrid Apps we can change the drivers perspective from native to
WEBVIEV or from one WEBVIEW to another WEBVIEW and vice versa. This
feature help us to automate apps which may change their perspective at
run time like, Payment get-way pages.
2. Selection of a device for execution from multiple devices connected to a
server at same time.
3. Pushing apps in background and resuming them after some time in same
state as it was left.
4. Running an app on multiple devices at same time using thread concept.
4 | Page
5. Selendroid
Architecture
Selendroid is based on the Android instrumentation framework, and therefore only
testing one app is supported. Selendroid contains four major components:
1. Selendroid-Client - the java client library (based on the selenium java client).
2. Selendroid-Server - that is running beside your app on the Android device.
3. Android Driver-App - a built in Android driver webview app to test the mobile
web.
4. Selendroid-Standalone - manages different Android devices by installing the
Selendroid-server and the app under test.
Selendroid-server is the main component responsible for the app automation. Along
with this Android Debug Bridge (adb) is used for the communication between
Selendroid standalone and android device.
Key Features
1. No modification of app under test required in order to automate it
2. Object identification made easy using built-in Inspector
3. Can integrate with selenium grid for parallel testing.
5 | Page
4.
Limitation
1. Can be used only for ANDROID and we need to look for other tool to test apps
on iOS.
2. Selendroid has multiple Android target API support till API 19. Currently there
is no support for API s > 19.
Moto G2
Android Version
Native App
(ExpenseManager-2.2.7)
Hybrid App
(BookMyShow-4.1.9)
Mobile Web
( on Chrome)
5.0.2
Asus
Zenphone
450CG
4.4.2
Tablet
Lenevo
.2.2
6. Appium
Architecture
On iOS, Appium sends command to a UIAutomation script running in Mac
Instruments environment. Apple provides this application called instruments which
is used to do lot activities like controlling and building iOS apps but it also has an
automation component where we can write some commands in JavaScript which
uses UIAutomation APIs to interact with the App UI.
6 | Page
Key Features
1. Supports cross platform testing i.e. Android and iOS
7 | Page
2. Though Appium supports Android API level >16, Appium provides Selendroid
mode to support lower API levels for android.
3. Test can be written in any language.
4. Similar to Selendroid, no modifications required in app under test. It works on
philosophy of testing the same app which is going to be submitted in app
store.
Limitations
1. Setup complexity and third party software dependency.
2. Appium uses an inbuilt tool uiautomatorviewer for object identification
which is not user friendly.
Nexus 5
Android Version
Native App
(ExpenseManager-2.2.7)
Hybrid App
(BookMyShow-4.1.9)
Mobile Web
( on Chrome)
5.1.1
Asus
Zenphone
450CG
4.4.2
7. Challenges Faced
Apart from the technical challenges the team had to grapple with the following
challenges
8 | Page
8. Go Forward Plan
1. Developing generalized function which can be used during projects for
Selendroid and Appium.
2. Working on features like zoom, drag and drop, grid testing and clip board.
3. Testing under different network conditions.
4. Developing a framework to simplifying script development and maintenance.
5. Test the developed feature on multiple available apps.
9. Installation Guide
Prerequisites Installation
Both the tools require Java and android SDK for working. So following are the steps
to install these prerequisites:
1. Download and install latest JDK
Set below system variables
a. JAVA_HOME : to jdk folder
e.g. C:\Program Files (x86)\Java\jdk1.7.0_79
b. PATH : to jdk\bin
e.g. C:\Program Files (x86)\Java\jdk1.7.0_79\bin
2. Install Android SDK
Set below system variables
a. ANDROID_HOME : to android SDK folder
9 | Page
e.g. C:\Users\kamruta\AppData\Local\Android\Sdk
b. PATH : add tools and platform tools path
e.g. % ANDROID_HOME %\tools; % ANDROID_HOME %\platformtools
3. Open command prompt, type \Android and enter. It should open SDK
manager if SDK is installed properly and all system variables are set.
4. Install ADT plugin in eclipse
5. Connect phone and check whether it is detected in eclipse.
6. If phone is not getting detected, Install PDA Net.exe
There is no specific installation requirement for Selendroid but we need to install
Appium server on our local machine (on server machine in case of grid execution)
for testing the app using Appium.
7. Install Appium Server.
10.
Change History
Versi
on
0.1
Created/Modified
by
Amruta Kauthekar
0.2
Amruta Kauthekar
0.3
Susmit Bansod
10 | P a g e
Date
Reviewed By
Aug
28,2015
Aug
31,2015
Sep
29,2015
Deepankar
Bandopadhya