You are previewing Robotium Automated Testing for Android.
O'Reilly logo
Robotium Automated Testing for Android

Book Description

Create and execute automated test cases for your Android apps using this hands-on guide to Robotium. A comprehensive guide to the framework, it takes you from first principles to advanced features and utilities.

  • Integrate Robotium with Maven to perform test case execution during build

  • Learn different steps to connect to a remote client from an android using Robotium

  • Understand the benefits of Robotium over other test frameworks

  • In Detail

    Automation testing on mobile devices has been around for a number of years, although it has really taken off with the advent of the Robotium Framework. With the help of automating test cases, business components are extensively reused and complex test cases are executed. Due to a number of different key features added to the Robotium Framework, it has become the world’s leading Android test automation framework and most of the industry experts and professionals are using this framework for testing their Android business applications.

    This practical guide will help you to create and execute automated test cases. You will also learn how to take advantage of the real power behind the Robotium Framework and all of its features, while being provided with a good grounding in how to use it in your Android test project.

    Starting with learning how to set up an Android environment for using Robotium, this book will then look at the various features of the Robotium framework, and take you through numerous examples that will help you to take advantage of the new features in Robotium, quickly and painlessly.

    This book will guide you through setting up the Android environment that is necessary to create a test project. You will also learn the benefits of using Robotium over other test frameworks, as well as solutions to the most common issues faced by users in this domain..

    Table of Contents

    1. Robotium Automated Testing for Android
      1. Table of Contents
      2. Robotium Automated Testing for Android
      3. Credits
      4. About the Author
      5. About the Reviewers
      6. www.PacktPub.com
        1. Support files, eBooks, discount offers and more
          1. Why Subscribe?
          2. Free Access for Packt account holders
      7. Preface
        1. What this book covers
        2. What you need for this book
        3. Who this book is for
        4. Conventions
        5. Reader feedback
        6. Customer support
          1. Downloading the example code
          2. Errata
          3. Piracy
          4. Questions
      8. 1. Getting Started with Robotium
        1. Robotium framework
        2. Features and benefits
        3. Setting up an Android environment
          1. Requirements
          2. Downloading the Android SDK
          3. Installing ADT
          4. Adding the Android SDK location
          5. Installing the latest SDK version
          6. Setting up the AVD
        4. Summary
      9. 2. Creating a Test Project Using Robotium
        1. Creating the AUT
        2. Creating a test project
        3. Creating a test case
        4. Adding the Robotium library
        5. Adding the package name in AndroidManifest.xml
        6. Robotium's test case code
        7. Running the test case
        8. Summary
      10. 3. Robotium APIs
        1. Solo
        2. API calls
        3. Resource ID in Robotium
        4. Understanding internationalization
        5. Summary
      11. 4. Web Support in Robotium
        1. API set
        2. Hybrid test example
        3. Summary
      12. 5. Comparison with Other Frameworks
        1. MonkeyRunner
        2. Robolectric
        3. UI Automator
        4. Calabash
        5. Summary
      13. 6. Remote Control in Robotium
        1. Software Automation Framework Support
        2. Working of a Remote Control for Android
        3. Robotium Remote Control using SAFS
        4. Summary
      14. 7. Other Robotium Utilities
        1. The RobotiumUtils class
          1. API set
        2. XPath API and syntax
        3. Robotium for pre-installed applications
          1. Test for only APK
          2. Signature process
        4. Summary
      15. 8. Robotium with Maven
        1. Automate Android app built with Maven
          1. Maven features
          2. Setting up Android SDK and ADT
          3. Setting up the environment PATH for Android Tools
        2. Build Android tests using Maven
        3. Summary
      16. Index