Direct Android Connections

If you want to connect an Android system under test (SUT) directly to the Eggplant Functional computer, you don't need to use Android Gateway. You can establish a connection from the Connection List in Eggplant Functional.

Connections via the built-in Android server must be made initially over USB so that Eggplant Functional can start the server. Connections over Wi-Fi are possible thereafter.

Launching the Android Server and Connecting over USB

Note: You must complete these steps before you can connect over Wi-Fi.
  1. Launch Eggplant Functional on your computer.
  2. On the Android device, navigate to Settings > Developer options and ensure that USB debugging is enabled.
  3. Also on the Android device, navigate to Settings > Security (This location might be Security & Screen Lock on some Android devices), and select the Unknown sources checkbox.
  4. Connect the device to your Eggplant Functional machine via USB. If no VNC server is present,Eggplant Functional pushes the Android server to the device.
  5. Create a new connection for the device in the Eggplant Functional Connection List. In the Server drop-down list, you should see the device represented by its serial number. Select the device.

    Connecting to Android devices in Eggplant Functional

    Note: If the connected Android device doesn't appear in the drop-down list, you might need to switch the Android Debug Bridge (ADB) version Eggplant Functional is using, which you can do on the Connections tab of Eggplant Functional Preferences.

    The server can be started over either port 5900 or 5901, but the default port for the running server is 5901.

    Give your device a Display Name to identify it in the Eggplant Functional Connection List, then click Save.

  6. To connect to the device, double-click the device in the Connection List or select it and click Connect. This starts the server and creates a connection to the device over USB. You can continue using connections via USB from this point or follow the directions below to make a Wi-Fi connection.

Allowing Mock Locations on Android Devices

In order to allow the SetDeviceLocation command to work on Android devices, you must change some developer settings on the device.

Android 4 and 5

Go to Settings > Developer Options > Mock Locations and turn on that functionality.

Android 6 and 7

  1. Go to Settings > Developer Options > Mock Locations and turn on that functionality.
  2. Go to Settings > Applications > eggSensor > Permissions and turn on Your location.


This topic was last updated on June 21, 2019, at 02:49:49 PM.

Eggplant icon | Documentation Home | User Forums | Support | Copyright © 2020 Eggplant