Book Image

Learning Selenium Testing Tools with Python

By : UNMESH GUNDECHA
Book Image

Learning Selenium Testing Tools with Python

By: UNMESH GUNDECHA

Overview of this book

Table of Contents (17 chapters)
Learning Selenium Testing Tools with Python
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Testing on Android


Appium drives the automation of Android applications using the UI Automator bundled with Android SDK. The process is quite similar to testing on iOS.

Appium works as an HTTP server and receives the commands from test scripts over JSON wire protocol. Appium sends these commands to the UI Automator so that they can be executed on the app launched in an emulator or real device. While doing so, Appium translates the JSON commands into the UI Automator Java commands that are understood by Android SDK. This process is shown in the following diagram:

When a command is executed against the app on the emulator or device, the target app sends the response back to the UI Automator, which sends it back to Appium. It translates the UI Automator responses into Selenium WebDriver JSON wire protocol responses and sends them back to the test script.

Writing a test for Android

Testing apps on Android is pretty much similar to what we did for iOS. For Android, we will use a real device instead...