Application security encompasses measures taken throughout the application's life-cycle to prevent exceptions in the security policy of an application or the underlying system (vulnerabilities) through flaws in the design, development, deployment, upgrade, or maintenance of the application.

Wednesday, July 18, 2012

Setting up the Android Test Environment

There are two main ways to test android based mobile applications, either by using real device or by using phone emulator. Here we will discuss both, lets start with phone emulator. It is not necessarily need to have access to the latest mobile devices. Thankfully, there's an easy way to run android on your Windows, Mac, or Linux computer. Google provides an android emulator with their SDK, which is designed to let developers test their applications on android before running them on handsets. This can be used to test drive android on our computer.

Requirements:

- Computer running microsoft windows operating system

- Oracle JRE 1.6.0.25 or higher
  Download Link: http://java.com/en/

- Android SDK
  Downloas Link: http://developer.android.com/sdk/index.html

Downloading the SDK starter package:

The SDK starter package is not a full development environment, it includes only the core SDK Tools, which you can use to download the rest of the SDK packages (such as the latest android platform). Make a note of the name and location of the SDK directory on your system, you will need to refer to the SDK directory later. Download android SDK from above link.

The SDK uses a modular structure that separates the major parts of the SDK, android platform versions, add-ons, tools, samples, and documentation into a set of separately installable packages. Install the SDK starter package, which you've already downloaded. Then launch the Android SDK Manager from Start -> All Programs

To download packages, use the graphical UI of the Android SDK Manager to browse the SDK repository and select new or updated packages. The Android SDK Manager installs the selected packages in the SDK environment.




Creating a virtual device:
 
With the AVD Manager you can create as many AVDs (Android Virtual Device) as you would like to test on. The AVD Manager is an easy to use user interface to manage your AVD (Android Virtual Device) configurations. An AVD is a device configuration for the android emulator that allows you to model different configurations of android-powered devices. Launch the AVD Manager from Start -> All Programs
 


In the Virtual Devices panel, you'll see a list of existing AVDs. Click New to create a new AVD. The Create New AVD dialog appears.



Give it a name (e.g. AVD_2.3.3), a platform target (e.g. Android 2.3.3 – API Level 10), an SD card size (e.g. 8 GiB), and a skin (e.g. Default(WVGA800)). You can also add specific hardware features of the emulated device by clicking the New button and selecting the feature.

Note: Be sure to define a target for your AVD that satisfies your application's Build Target (the AVD platform target must have an API Level equal to or greater than the API Level that your application compiles against).

Your AVD is now ready and you can launch an emulator with the AVD by selecting a device and clicking Start.

No comments:

Post a Comment