Single Sign-On is available for Genymotion SaaS now!

Instrumented Tests from Jenkins with Genymotion SaaS

This tutorial explains how to automate your instrumented tests from your Jenkins continuous integration server with Genymotion SaaS, using gmsaas command line tool.

Prerequisite

Configuring a Jenkins job with gmsaas

To configure the Jenkins job that will run your instrumented test, from Jenkins, go to menu Configure.

1. In Source Code Management

Enter the location of the application source code:

2. In the Build section:

Note

  • <GMSAAS_PATH> is the location of gmsaas on your Jenkins, <API_TOKEN> is your Genymotion SaaS API Token. This authenticates you to Genymotion SaaS.
  • <RECIPE_UUID> is the device recipe/template uuid (you can get all the recipes by using the command gmsaas recipes list) and <NAME> is the name you wish to give to the instance.
  • <NAME> is only used as a tag – you should not use it to issue commands from gmsaas to an instance. Use the instance UUID instead.

Add Execute shell to run commands and add the following commands:

<GMSAAS_PATH>/gmsaas auth token <API_TOKEN>
<GMSAAS_PATH>/gmsaas instances start <RECIPE_UUID> <NAME>
<GMSAAS_PATH>/gmsaas instances adbconnect <NAME> [--adb-serial-port <VALUE>]

Add Invoke Gradle script to run your instrumented test.

Tick Root Build Script Dir. To have more logs, in Switches, enter --debug --stacktrace

In Tasks, add connectedAndroidTest (cAT):

3. In the Post Build section

Add Publish JUnit test result report & Publish HTML reports to get test reports:

Add Execute a set of scripts to stop the device where the tests were run. In Build steps, add Execute shell section and add the following command:

<GMSAAS_PATH>/gmsaas instances stop <UUID>

where <UUID> is the UUID of the virtual device you created (not the <NAME>!).

Running the builds

You can run the builds manually by clicking Build with Parameters or have it automatically built by configuring a scheduled build.

Viewing test reports

Once your tests have run, you can view your test reports from Test Report.

Table of Contents

Select Product Portal

SaaS Platform

Access to our SaaS solution and use virtual machines in the cloud on any web browsers.

Or

Or

Desktop Platform

Access to manage your Genymotion Desktop licenses, your invoices and account information.

Select a Cloud provider Marketplace

How to get a quote for multiple Business Licenses?

  1. You need a Genymotion Desktop account. If you haven’t one yet, you can create it here.
  2. After creation and activation, or if you already have an account, follow this link.
  3. Add the number of desired licenses to your shopping cart and click “Continue to Billing”
  4. Add a shipping address, or select one if you already created one.
  5.  In the next page, click “Get a quote”:
    Payment details
  6. A quote will be automatically generated in PDF format.

Genymotion Device Image for Cloud providers
- Private Offer -

Genymotion Device On-premise
- Contact Us -

Genymotion SaaS
- Increase Maximum Simultaneous devices -

Genymotion SaaS Annual Plan
- Get a Quote -

Genymotion SaaS Premium Plan
- Get a Quote -

Personal Use - Free

Genymotion Desktop for personal use is not suitable for trial or POC: you will not get any assistance and some features will be disabled. If you have already selected “personal use” and wish to get a trial license, please contact our Sales at [email protected].

Technical support is not available with Genymotion Desktop free edition for personal use. For more details, please refer to Genymotion conditions of use (Personal Use).

The following features are not available in personal use mode:

Follow these steps to get Genymotion Desktop and activate personal use mode:

  1. Go to the Download page and get the latest version for your system.
  2. Follow the instructions from Genymotion Desktop quickstart guide to install Genymotion Desktop.
  3. Launch Genymotion and click CREATE to create an account. You should receive an activation email within an hour. If not, make sure to check your spam.
  4. After activating your account, return to Genymotion and log in with your credentials.
  5. Select personal use when prompted.
  6. Read Genymotion Desktop quickstart guide carefully to setup Genymotion for your needs.

Indie Plan Application Form

This plan is strictly reserved to individual workers (freelancers, self-employed).

Educational Plan Application Form

The Educational plan is restricted to:

  • schools, teachers or students who wish to use Genymotion Desktop for tuition
  • students who wish to use Genymotion Desktop for a school project

It is subject to valid proof (student card, teacher card, etc.)