Selecting Right Technology For Your Enterprise Mobile Solution

Selecting Right Technology For Your Enterprise Mobile Solution

The main purpose behind writing this article is to focus on the different variants of mobile technologies present in the market.

The mobile market has been quite crazy over the last 5 years. We have seen too many trends, techniques and technologies emerging and dissolving over the period of time. This article assumes that you are a mobile app developer who wishes to choose the best technology for his Enterprise Mobile Solution.

Let’s go through different mobile development technologies generations one by one and see their advantages/disadvantages.

  • 1st Generation (Native)
    • iOS – Objective C / Swift
    • Android – Java
    • Windows -.NET
    • Advantages
      • Native UX
      • High Performance
      • Hardware and Platform Access
    • Disadvantages
      • Single Platform
      • No Unified Codebase
  • 2nd Generation (Hybrid HTML and JavaScript)
    • PhoneGap
    • Appcelerator
    • Apache Cordova
    • Kony Mobile
    • Advantages
      • Multiple Platform
      • Unified Codebase
    • Disadvantages
      • No Native UX
      • High Performance
      • Hardware and Platform access
  • 3rd Generation 
    • Xamarin
    • React
    • Advantages
      • Multiple Platform
      • Native UX
      • High Performance
      • Unified Codebase
      • Hardware and Platform access

There is a transition from Native, then hybrid and now cross platform. The technology is getting much better and faster day by day.

The native generation is still transition proof and many prefer it over the later two generations. It is because it offers seamless performance, support, and resources. The direct support from Apple and Google is an important factor in selecting these technologies.

The growth in the second generation is stagnant due to the rise of the third generation. People are using Cross Platform (Native) to use a single language for development across platforms and also share more than 40% codebase to reduce time-to-market.

The only factors which help people use the cross-platform app (native) over the normal native apps are code sharing, time-to-market and resource constraints. Those who fall in this category are going towards cross-platforms apps which not only have native UX but also performance.

Also, I see that many still are confused between Hybrid and Cross Platform. Let me tell you, these are completely different kind of technologies. Let’s understand their definition:

Cross Platform:

It is a solution developed to minimize development efforts by compiling the source code for further execution on multiple mobile platforms. But the result of each separate compilation will be an individual executable file. For example, iOS executable file has .ipa extension, and for Android, it is *.apk, etc.


These apps are developed using web technologies like HTML, CSS, Javascript etc. It is an app which runs in a “wrapper” and serves not as a web page, but as a standalone application.

Good professionals are very sensitive to the concept of development, efficiency and productivity and most of them have unique vision “what is good and what is bad?”, but usually, it is all about technology set that use, care and cherish. In general, it may happen that the budget decides everything, so the basic background for the emergence of cross-platform solutions was their benefits to business, namely:

  • Need a single developer who can develop a mobile app and deploy it for different OS. Thus you eliminate a need for full-time developers for every single OS;
  • Difficult to find developers for individual platforms when the business requirement is critical
  • Ease to manage the app versions for different mobile operating systems

Let’s see some key takeaways and considerations to compare Xamarin and Hybrid Mobile App. To understand the difference in a much better way with quantification, I have created a sample app which demonstrates and provides the detailed analysis of the key points as follows.

Key Takeaways:

  1. Cross Platform (Native) app fulfills most of the requirements whereas Hybrid app was unable to deliver on the key piece of functionality without requiring custom Objective-C and Java

  2. Xamarin performs CPU-intensive tasks much faster than Hybrid HTML

  3. Cross Platform Native loaded large datasets faster than Hybrid HTML

  4. Cross Platform Native used less memory than Hybrid HTML

User Experience Key Considerations:

  • Native look and feel
  • Hardware & Platform Access
  • UX Design Capability

Developer Productivity Key Considerations:

  • Volatility of HTML frameworks
  • API Access Extensibility
  • Stack Complexity
  • Strongly-Typed Development
  • Compilation Time


Performance (ms) – to load and display a single page

  1. iOS
    • Xamarin – 1400 ms
    • Hybrid – 2000 ms
  2. Android
    1. Xamarin – 3690 ms
    2. Hybrid – 4502 ms

Compile Time (sec) – to compile the mid-size app

  1. iOS
    • Xamarin 34 sec
    • Hybrid  18 sec
  2. Android
    1. Xamarin 32 sec
    2. Hybrid 25 sec

Code Reuse (%) – considering the basic flows and libraries used

  1. Xamarin Native – 45%
  2. Xamarin Forms – 96%
  3. Hybrid Mobile – 99%

App Size (MB)

  1. iOS
    • Xamarin – 35 MB
    • Hybrid  – 11 MB
  2. Android
    1. Xamarin – 11 MB
    2. Hybrid – 6 MB

TCO Key Considerations

  • UFC (Upfront Cost) vs Maintenance
  • End-UserProductivity App Adoption
  • Agility Costs


The selection of technology for your enterprise solution is a process which consists of various parameters. Some of them are budget, time-to-market, user experience, performance, explicit requirement and code reuse.


Solutions to common issues working with Xamarin

Solutions to common issues working with Xamarin

Hi everyone, I have been thinking to write this article for quite a while now. Being continuously working on Xamarin in-depth and proposing solutions to the clients, you face some common problems. This article focuses on the resolving these issues faced by Xamarin developers and help them for smooth Xamarin Solution.

You may find some problems related to core development and some related to the solution proposal. If you feel anything is missing and needs to be present in this list, feel free to drop a comment and I would be really happy to add it to this list with mentioner’s name.


Problem 1: It may happen that you are unable to access Android SDK as it was installed in the administrator folder and was not having required permission to access it.

Solution: User must have Admin rights to access that folder.

Problem 2: Unable to provide internet access to emulator even after changing the proxy settings.

Solution: You can try to increase the target API level and install the ARM EABI v7a system image for it and then change the proxy settings of the emulator.

Problem 3: Emulator starts and stops immediately. Failed to create Context 0x3005 for an emulator.

Solution: It requires to update the Intel GPU driver.

Problem 4: Unable to use the local database in Xamarin app as it cannot find the physical path of the database file.


Xamarin creates its own database in its APK file as follows:

Set absolute path for folder creation like:

String path = System.Environment.GetFolderPath (System.Environment.SpecialFolder.Personal);

String Applicationfolderpath = System.IO.Path.Combine (path,”Database1”);

Where Database1 is the name of the newly created database

Create the folder path like below:

System.IO.Directory.CreateDirectory (Applicationfolderpath);

Create database in set path like below:

String databasefilename = System.IO.Path.Combine (Applicationfolderpath,”User.db3”);

Where User.db3 is the name of the database file.

SQLite.SQLite3.Config (SQLite.SQLite3.ConfigOption.Serialized);

SQLite.SQLiteConnection Db = null;

Db = new SQLite.SQLiteConnection (databasefilename);

Var res = db.CreateTable<Classname> ();

Problem 5: Unable to provide WCF service on another machine

Solution: Provide service on other machine using IIS manager.

Problem 6: What is the difference between Page and Activity?


  • Page
  1. It is a visual that occupies most or all of the screen and contains a single child.
  2. A Xamarin.Forms.Page represents a View Controller in iOS or a page in Windows iPhone.
  3. On Android each page takes up the screen like an Activity but Xamarin.Forms Pages are not Activity.
  • Activity
  1. Activity represents a screen in an application.
  2. Android Application Architecture doesn’t have a single application instance so there is an aggregation of one or more activities.

 Problem 7: Mac machine is required to develop iOS app on Xamarin


Problem 8: Visual Studio for showing option to select an emulator to debug and run iOS simulator on Windows only


  1. Build the application
  2. Select the emulator from Device Manager
  3. Start the Emulator
  4. Click on the Start button of the Visual Studio
  5. It will then display error as “deployment failed due to fast dev process”
  6. Go to Project=>Properties=>Android application then uncheck the “use FastDev process”
  7. Again click on start
  8. With the latest updates for Xamarin.iOS, you can run iOS simulator on Windows Machine only. To enable this, go to settings and check run emulator on windows option

Problem 9: How to develop iOS app using Visual Studio.


Required Components

For Mac

  • Latest iOS SDK
  • XCode latest version
  • Mac OS X 10.9.4 + or 10.10 above

For Windows

  • Windows 7 or higher
  • Visual Studio 2012 Professional or higher
  • Xamarin’s plugin for Visual Studio

Create Xamarin.forms blank project in Visual Studio. It will then ask for Mac IP or Mac name. Provide the required information and connect it to the Mac machine.

 Problem 10: How to add an application on Google Play Store.


  1. Create the APK file of the application
  2. Navigate to Google Developer Site
  3. Logging into Google Developer Console. If you do not have an account create a new account. The last step in the process of creating a developer account is paying a one-time $25 developer fee using a credit or debit card
  4. Click on the button Add New Application
  5. Initialize APK Upload. Select correct language and write the name of the app as you wish it to appear in the google play store. Then select upload APK button
  6. Click on Upload your first APK to Production button centered on your screen
  7. Select and upload APK file
  8. Navigate to the store listing tab on the left side and write the description in the description box which will appear on the google play store
  9. The next step in the store listing tab is to add screenshots
  10. Then add a store listing icon
  11. The final step on the “Store Listing” page is filling out the categorization, contact details, and privacy policy, located below the icon selection area. Fill out the required fields as you wish and hit save. The “store listing” tab should now have a green check-mark next to it
  12. Click on Price and Distribution tab where you will select paid or free, distribution countries, and check the boxes saying that your app complies with the guidelines and the US export laws. Click on save button
  13. Once all the three tab at the left have a green mark you are then able to select “Publish this app” from the “Ready to Publish” drop-down menu in the top right corner of the developer console. A confirmation bar should appear at the top, stating that your app will appear in the Google Play store in just a few hours

Problem 11: On creating new Xamarin.forms project in Visual Studio it is giving the error “Could not add all required packages to the project.

The following packages failed to install from ‘C:\PROGRAM FILES (X86)\MICROSOFT VISUAL STUDIO 12.0\COMMON7\IDE\EXTENSIONS\XAMARIN\XAMARIN\\Packages'”:

Xamarin.Forms. Could not install package ‘Xamarin.Forms’. You are trying to install this package into a project that targets ‘Xamarin.iOS,Version=v1.0’, but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author”.


  1. To solve this issue open your visual studio go to tools -> Extensions & Updates -> select updates -> select visual studio gallery then update your NuGet package manager
  2. Update the Visual Studio Version if the updates for it are available. Update it using the same above procedure as for updating NuGet manager

Problem 12: On creating new Xamarin.forms project in Xamarin Studio it is giving the error “Could not add all the required packages to the project”.


  1. Add the xamarin.forms packages
  2. Install PCL libraries. Following is the link to download PCL libraries    00cb3caf4981/
  3. After this reinstall or repair xamarin
  4. In Xamarin Studio, right click on the project select options=>build=>general then change the target framework to that profile which is installed.

Problem 13: Windows application prerequisites and steps.

Solution: Prerequisites for Windows app

  1. You need the latest version of windows
  2. Microsoft Visual Studio: Microsoft Visual Studio 2013 helps you design, code, test, and debug your apps
  3. If you don’t already have Visual Studio 2013, install the free Visual Studio Express 2013 for Windows

If you already have Visual Studio Professional 2013 or a higher edition, get Update 3 for Visual Studio 2013 to add the Windows Phone development tools and other enhancements to your existing installation:

(Optional) Register your Windows phone device for development:

It’s important to test your Windows Phone Store apps on a real phone. Before you can deploy apps to your Windows Phone, you have to register the phone for development.

  1. Connect your phone to your PC.
  2. Run the Developer Phone Registration tool (phonereg.exe).

Register as an app developer:

Now that you’ve installed the tools you need, you need a developer license or a developer account. A developer license is free and lets you develop Store apps, but you need a developer account to sell your apps in the Windows Store and the Windows Phone Store.

  1. To get a developer license, just launch Visual Studio. You’ll be prompted to get a developer license
  2. To get a developer account, go to the Signup

Steps to create a Project:

  1. Make sure you’ve downloaded and installed the Windows Phone SDK
  2. Launch Visual Studio from the Windows Start screen. If the Registration window appears, you can register the product, or you can temporarily dismiss the prompt
  3. Create a new project by selecting the FILE | New | Project menu commandIn the New Project window, expand the installed Visual C# or Visual Basic templates, and then expand Store Apps. Select the Windows Phone Apps
  4. In the list of Windows Phone Apps templates, select the Blank App (Windows Phone)
  5. At the bottom of the New Project window, type MiniBrowser as the Name of the project
  6. Click OK. The new project is created and opens in Visual Studio


Installation instructions for Xamarin

  • Install Java JDK
  • Install Android SDK (Including all API levels)
  • Visual Studio 2012 Professional
  • Install Xamarin Studio

If Xamarin Studio is installed before Visual Studio then Xamarin needs to be reinstalled

Problem 13: When your codebase is on TFS and linked with the local workspace present on Windows machine. How to design UI for iOS apps easily.


  1. It is recommended that you must connect with Mac agent and share your codebase for mac machine user. This will enable that same codebase is present on both machines
  2. Once the codebase is shared, select the main folder and uncheck read-only option if present by any chance
  3. Open the project in Xamarin Studio on Mac
  4. Right click on the Storyboard file inside Xamarin Studio and open it with XCode

The support by iOS designer in Xamarin is not much fast yet and you are always recommended to use XCode to design your iOS app. Once the changes in XCode are done, they are reflected in your Xamarin project

Problem 14: How do I share code in Xamarin Native apps?


You can create .NET class library if you want to share code between iOS and Android apps. It is recommended for a normal mobile app to consume to class libraries like Common Code and Service Connection Code.

If you wish to extend support to Windows Phone as well, then .NET class library does not work there. You are advised to use Portable Class Library (PCL). This library can be used in iOS, Android and Windows Phone Xamarin apps.

Problem 15: What are different types of Xamarin apps and which one should I propose to my client?


  1. If you wish to go native, you can go for Xamarin.iOS, Xamarin.Android and Xamarin.Mac
  2. If you wish to go cross platform with UI sharing, you can go with Xamarin.Forms option
  3. If you wish to develop windows app which works on Windows Phone, Windows 10 then go with Xamarin UWP (Universal Windows Platform) app
  4. Still there are lot of different templates being created as the new versions of Xamarin.Studio are coming up

These were some common problems faced by developers. I am working on Xamarin in depth and would keep on posting some interesting information on this blog regularly. If you have any questions, you can post in comments section.

Thank you.





Continous Integration for iOS and Android apps using Xamarin

Continous Integration for iOS and Android apps using Xamarin

Why Continuous Integration?

In the complex projects, developers and testers (also called as full stack developers in agile methodologies) simultaneously work on their modules. You can imagine several products are getting created in parallel leading to huge amount of integration work in the regular intervals of time. A single change in the development code needs to be checked into the code repository. This delta is then integrated, tested to make sure that the changes didn’t add any defects, hence a stable product, stable build.

This process is called as Continuous Integration (CI). It lets you find defects in the least possible time in the development cycle from the time of their occurrence. It helps to identify code coverage and facilitate the stability of the release build.

Pre-requisites for Xamarin CI using TFS

For this post, we are going to concentrate on using TFS On-Premise Server for Continuous Integration. When using TFS (i.e. configuring Build.vNext), first steps is to log in and configure the agent pools. Agent Pool is called as a collection of several build agents (i.e. services running on the operating system / build server and listens for builds from TFS). This agent pool needs to be created first and then the build agents. It is to be noted that build agents should be free and should also meet the demands of the particular build requested. For example, an iOS build can only be requested to build agent which has Xamarin.iOS capabilities, similarly for Android also. The choice of how many pools or agents you need totally depends on the different projects/purposes.

For the management of the agent pools, you should know below account groups:

  1. Administrator Account Group
  2. Service Account Group

Administrator account group member is allowed to add, remove and configure agents in the pool whereas Service account group only let you run builds.

At first, you need to add your user account in Agent Pool Administrators group by logging into TFS. Later, you can create any number of Agent Pool Service Accounts for the production environment.

CI for Xamarin.Android

This section will address the complete steps required to perform the continuous integration process for Xamarin.Android Native Apps. This will also consist of the process to add the windows build agent to build the source code for a project.

Create and Configure Xamarin.Android Build Agent on Windows

This section will provide you step by step details for creation of Xamarin.Android Build Agent on Windows.

When Build agent receives a build from TFS Server, it executes the steps in the build definition. Currently, you have to use a Windows build agent to build Windows/Windows Phone apps and Xamarin.Android apps and a cross-platform build agent on the Mac to build Xamarin.iOS projects. In the future, the cross-platform build agent should also be able to build Xamarin.Android projects too.

This section will provide you step by step details about different items to be installed on your machine to satisfy it as a Windows Build Agent:

Install below software’s on the build machine.

  1. Xamarin (Latest Version)
  2. Java JDK 1.7
  3. Android SDK (Latest Target Version)

Please note that ANDROID_HOME and JAVA_HOME environment variables should be set to locate the required components and advertise them as capabilities of a build agent. Once done, you need to download the agent from TFS, configure and run the build agent.

For configuration of build agent, you need to create a BuildAgents (or any name with which it makes sense) folder in the C:\ drive to store all of the agents in one machine. You can create AndroidAgent folder in it and extract the agent zip file downloaded from TFS. Once done, open Windows PowerShell as Administrator and run .\ConfigureAgent.ps1, press enter. Fill in the required details for the agent and you are done!

The Windows Build Agent is successfully created with the Xamarin.Android Capabilities. The agent starts as a service in Windows. If you wish to start/stop the agent manually, you can stop the service.

Create Xamarin.Android Build Definition

This section will provide you step by step analysis on the creation of a Build Definition for Xamarin.Android project. It uses Windows Build Agent for creation and deployment of the builds.

  1. Navigate to TFS Team project Home page, click on the Build tab and click Add button to add new build definition
  2. Select Xamarin.Android template and click OK. This will create a new Build Definition with some pre-defined steps

There are different tabs associated with the creation of build definition like Build, Options, Repository, Variables, Triggers, General, Retention and History.

You can modify build steps to build particular Android project present in the TFS Code Repository, sign APK file as a build artifact to TFS. Some more steps are as follows:

  1. For the Target input field, type: PackageForAndroid (this will trigger the build target that will create .APK package once the project is built)
  2. Add Android Signing builds step, check the ‘Sign the APK’ option and enter valid Keystore details as required
  3. Add Publish Build Artifacts step and put ‘Path to Publish’ as $(build.binariesdirectory)\$(BuildConfiguration)

Please note that BuildConfiguration is the variable created under Variables tab which will be used runtime.

  1. Check the Continuous Integration (CI) in Triggers tab or you can schedule the trigger as per your project requirements
  2. Select the Default agent Queue/Pool which is already created
  3. Save the changes and click OK

Once the build definition is created, you can queue new build for the definition and if everything has been configured correctly, your build definition should finish with the message “Build Succeeded”. If failure, you can check logs about the exact cause behind the issue.

CI for Xamarin.iOS

This section will address the complete steps required to perform the continuous integration process for Xamarin.iOS Native Apps. This will also consist of the process to add the windows build agent to build the source code for the project.

Create and Configure Xamarin.iOS Build Agent on Mac OS

This section covers the creation of the cross-platform build agent and configuration for Xamarin.iOS project. The cross-platform agent has been recently introduced along with Visual Studio 2015. This agent can only be configured and executed on Mac OS X and Linux Machines for build definitions created using the Build.vNext tools included in TFS 2015.

Please note that the cross-platform agents are written in Node.js and you can install/update/run them using Node.js.

This section will provide you step by step details about different items to be installed on your machine to satisfy it as a Mac OS X Build Agent:

  1. Install below software’s on the build machine:
  • Xamarin
  • Xcode
  • js
  1. The next step is to install the VSO Agent using the following command in Mac OS X Terminal:

sudo npm install vsoagent-installer –g

If you think that this will create an agent for you, then it is not. This is just going to create a copy which will be used later to create actual agents.

  1. To provide permissions for Node Package Manager, please run below command:

sudo chown –R $USER ~/.npm

  1. It is recommended to create a BuildAgents folder in the root of your Macintosh HD partition to store all of the agents you wish to create (you can have multiple agents running on the same machine). Inside this BuildAgents folder, create another folder called Agent1 (or whatever you want to name your build agent). You can create these folders using the Finder
  2. Install the VSO agent in the folder you created and run ./ file to start configuration
  3. The console will ask following questions to configure the cross-platform build agent on Mac OS X:
    1. Enter alternative username: You need to enter the username of the account that was configured to administer build agents earlier
    2. Enter alternative password: Enter the corresponding password for the account chosen in the previous step
    3. Enter server URL: You need to enter the TFS URL
    4. Enter Authentication Type: Click enter to continue
    5. Enter agent name: You can use whatever name you want to here. This name is to identify agent in the agent pool
    6. Enter agent pool name: This allows you to add an agent to a specific pool which is already available in TFS. If you do not pass this value, the agent will be added to the default pool

The cross-platform build agent is now successfully configured with Xamarin.iOS capabilities. Run ./ to start the agent as a service. Do not close the Terminal window until you want to stop the build agent. You can stop the build agent by pressing Ctrl-C.

Create Xamarin.iOS Build Definition

This section will provide you step by step analysis on the creation of a Build Definition for Xamarin.iOS project. It uses Mac OS X Build Agent for creation and deployment of the builds:

  1. Navigate to TFS Team project Home page, click on the Build tab and click Add button to add new build definition
  2. Select Xamarin.iOS template and click OK. This will create a new Build Definition with some pre-defined steps

Most of the steps mentioned in the build definition for Android are pretty similar.

You can modify build steps to build particular iOS project present in the TFS Code Repository. You need to modify Xamarin.iOS build steps so the build agent will build the solution and upload the .ipa package that is created as a build artifact to TFS. Some more steps are as follows:

  1. Click on ‘Add Build Step…’ and select ‘Publish Build Artifacts’ item
  2. Looking at the new ‘Publish Build Artifacts’ build step, In the ‘Copy Root’ input field type: $(build.binariesdirectory)\$(BuildConfiguration)
  3. Check the Continuous Integration (CI) in Triggers tab or you can schedule the trigger as per your project requirements
  4. Select the Default agent Queue/Pool which is already created
  5. Save the changes and click OK

Once the build definition is created, you can queue new build for the definition and if everything has been configured correctly, your build definition should finish with the message “Build Succeeded”. If failure, you can check logs about the exact cause behind the issue.

This way your Continous Integration System for both Android and iOS apps using Xamarin can be set up. I will cover more details about Xamarin in coming posts.


Hi All,

I have launched a new website today which aims at providing a core technical articles for the Computer Science Engineers.

Please have a look at it and provide your comments/suggestions for the improvement in the initial stage.

– Hrushikesh


This post is on the topic ‘Robotium – Testing Framework for Android’. I had worked on Robotium framework sometime back so just wanted to share the information related to the same with you all.

What is Robotium?

Robotium is a test framework created to make it easy to write powerful and robust black-box test cases for Android applications.


  • With the support of Robotium, test case developers can write function, system and acceptance test scenarios, spanning multiple Android activities
  • Robotium has full support for Activities, Dialogs, Toasts, Menus and Context Menus
  • Robotium is a Free tool, can be used by individuals and Enterprises
  • Robotium is a “Black Box” testing tool that is able to simulate and automate user interaction such as touching, clicking, text entry and any other gesture that is possible on a touch supported device
  • The tests could either be executed on the Android simulator (AVD – Android Virtual Device) or on a real device
  • Robotium is built on the Java programming language and the JUnit 3 test framework
  • Robotium can be used both for testing applications where the source code is available and applications where only the apk is available


Since the Robotium test tool is open source, no cost is associated with this.

Benefits of Using Robotium:


  • Easy to write, shorter code. Minimal time needed to write solid test cases
  • You can develop powerful test cases, with minimal knowledge of the application under test
  • The framework handles multiple Android activities automatically. Readability of test cases is greatly improved, compared to standard instrumentation tests
  • Automatic timing and delays
  • Automatically follows current Activity
  • Automatically finds Views
  • Automatically makes own decisions (ex: When to scroll etc.)
  • No modification to Android platform
  • Test execution is fast
  • Test cases are more robust due to the run-time binding to GUI components
  • Integrates smoothly with Maven or Ant
  • With the newly released Robotium 4.0, it has full support for hybrid applications. Hybrid applications are applications that use WebViews to present the HTML and JavaScript files in full-screen, using the native browser rendering engine


Robotium Features:


  • Screenshots can be captured inside Robotium
  • Robotium can be run without source code
  • It’s possible to generate code coverage reports for your Robotium tests
  • Robotium is able to detect the contents of a Toast on the screen
  • Localised strings can be used (Needs source code)
  • Robotium test can be run from the command line
  • Robotium offers many methods that react to different graphical elements within an Android app, such as


clickOnText(“Secure Login”);












  • With these simple methods, robust automated tests can be implemented really quickly. By combining them with JUnit, you then have additional ways of checking values or user interactions on the device for the correct response, which in turn makes these tests even more powerful




  • Cross Activities testing, Robotium is able to work only with same certificate app, otherwise you will get inject events exception (e.g. you are not able to do clicks on screen keyboard)
  • Robotium has no mechanism to handle expected/unexpected alerts/popus/dialogues. For example, iOS Javascript tests has very simple boolean flag and callback for handling alerts
  • Robotium has big problem with auto scrolling methods. For example, if you are looking for the text, which is not shown, Robotium will stack in the end of the scroll view and make assertTrue(false) to stop scrolling
  • Robotium has assertTrue(false) logic for reporting problems/unexpected situations instead of returning some Enum value or boolean (success/fail) so for a good stress tests which are run 24/7, you need to add your own methods which will not stop test, just handle ‘method fail to click x y’ result value
  • The scope of test cases in Robotium is limited to a single application and does not support for more than one application. Test project is always locked with a target package, which need to be tested and going outside of the package is not allowed
  • Android native API’s (Contacts, Widgets etc.) used in the Android application cannot be tested using Robotium. While executing test, if focus is switched to Native application, it will not come back to the Test application and Test will fail
  • Robotium is not able to handle the flash or web components. It only works with android components. You could send in clicks by using clickOnScreen() or assert that a certain Activity is shown but that is all. You will not be able to write tests where you verify or work with the web or flash components
  • Test Execution is very slow
  • Test cases are complex to implement
  • Not able to handle multiple activities
  • Robotium does not support flash and web based applications.
  • Robotium does not work on Canvas.


Future Enhancements:


  • Robotium Remote Control similar to Selenium RC
  • Integration with BDD tools such as cucumber
  • Automatic measurement of user interface test coverage
  • Generate screenshots on failure
  • Multiple device support


To get started with implementation, you can refer this link.

Talking off the topic, It’s great to be back on the blog after a long long time. I will make sure you get the latest updates on time 🙂

@MsWizKid signing off!

Enjoy 🙂

Visual Studio LightSwitch 2011 Tutorial Video

Hi guys,

I recently attended one session on Microsoft Visual Studio LightSwitch 2011 at Persistent Systems Limited and found it very interesting and helpful. You can get all the information about LightSwitch from here .

According to me, some of the important features of Microsoft Visual Studio LightSwitch 2011 which I liked are as follows:

1) Easier facility to add data source and retrieve data from MS SQL Server, MS SQL Azure, MS SharePoint and Windows Communication Foundation

2) Business friendly data types like EmailAddress and PhoneNumber are present which are very helpful

3) One can create screens for your data quickly using shortcuts present in the action bar

4) One can choose from already present common screen templates and match the screen to the appropriate data source

5) Edit screen layout using a Tree Control

6) Screens automatically create input field for the entity model they are matched to

7) Business data types enable additional validation and functionality without writing a single code

8) Export to Microsoft Excel is directly available

9) It enables non-programmers to develop professional, quality business applications

10) Customizable templates enable new and creative user experiences

11) LightSwitch features support for many devices—including touch-screen support—is built in

12) If you have already built any desktop application and in a need to convert it to web application then it is very easy to convert that desktop application with a single button click and your web application is ready to deploy.

Different shells are available for the applications in LightSwitch so that at any point of time, one can easily change the UI as quickly as possible with a single button click.

The limitation of LightSwitch which I felt is that UI is completely dependant on the shell. Different templates could not be added in the same application at one point of time.

I am finding it very much useful and try to work with it once a week. To download Microsoft Visual Studio Lightswitch, kindly use this link.

Enjoy 🙂