To start writing automated tests for your app, using Appium, we need to do some setup beforehand. We will need the following setup before writing our tests.
- JDK (Java Development Kit) installation
- Android SDK installation (This post)
- Appium installation
- IDE of your choice (to write the actual tests)
This post will be a part of your step by step guide to setup Appium for Android on Windows OS.
We have already seen JDK installation in our previous post. Here we will continue from where we left. We will do the Android SDK installation.
- Android SDK API >= 17 (Additional features require 18/19)
- Appium supports Android on OS X, Linux and Windows.
For the scope of this post, we will consider Appium for Android on Windows
- Go to Android developer’s site and download the Stand-alone SDK tools
- Android is now officially ending its support for Eclipse ADT plugin, hence we recommend using the stand-alone SDK tools.
- Download the compressed zip file.
- Create a directly called “Android” in any location that’s easy to remember. Say “C:Android”
- Extract the contents of the downloaded zip file to the new directory you created, “C:Android”
- The Android SDK archive initially contains only the basic SDK tools. It does not contain an Android platform or any third-party libraries.
- To get all the necessary tool, double click on “SDK Manager.exe”
- Select the packages for the Android version of your choice – I have selected Android 4.4.2 (API 19).
- SDK Platform
- ARM EABI v7a System Image
- Intel x86 Atom System Image
- Google APIs (System Image).
- Select Android SDK Platform-tools & Android SDK Build-tools (these will add platform-tools folder to your location of SDK content)
- Click on Install 6 packages
- Accept license and continue downloading/installing the packages.
These will help us create and run virtual device running Android 4.4.2
- Right-click the My Computer icon on your desktop and select Properties.
- Click on Advanced systems settings.
- Click the Environment Variables button.
- Under System Variables, click New.
- Enter the variable name as ANDROID_HOME.
- Enter the variable value as the installation path directory where you have all the contents (example – C:Android) extracted.
- Click OK.
- Edit the path variable under “System variables” and enter the path like C:Androidplatform-tools; (change this path according to your installation locations)
- Click OK/Apply Changes.
- From the SDK manager, click on tools > Manage AVDs
- From the SDK installation folder, double click the “AVD Manager.exe”
If you like the post or found it useful, don’t forget to share it. Feel free to comment and let us know your thoughts.