Questions tagged [monkeyrunner]

Monkeyrunner is tool from Android SDK which provides an API for writing programs that control an Android device or emulator from outside of Android code.

Monkeyrunner is a host side application to control a monkey instance on a device.
Monkeyrunner provides some useful helper functions to control the device as well as various other methods to help script tests.

The monkeyrunner tool provides an API for writing programs that control an Android device or emulator from outside of Android code.
With monkeyrunner, you can write a Python program that installs an Android application or test package, runs it, sends keystrokes to it, takes screenshots of its user interface, and stores screenshots on the workstation.

The monkeyrunner tool is primarily designed to test applications and devices at the functional/framework level and for running unit test suites, but you are free to use it for other purposes.

476 questions
0
votes
1 answer

Rebooting android using monkeyrunner

I have this application which I'm testing. I use a script which automatically installs the app but I also want to restart the device. This is important as after the installation I run a monkey-test on the device and all kind of quirks and bugs may…
0
votes
2 answers

Android: measuring similarity between two activity pages

I'm using monkeyrunner and androidviewclient to crawl the GUI of some android apps (i.e., this). BTW, it is working great! The thing is that sometimes when you click on a clickable component it will open up the same page that you are in or you have…
Ehsan
  • 4,334
  • 7
  • 39
  • 59
0
votes
1 answer

MonkeyRunner and androidviewclient "dump-all-windows-lib.py" example is not working

I'm running this example, but it keeps showing this error: windows = vc.list() File "/Users/ehsan/Desktop/Android/adt-bundle-mac-x86_64-20130514/sdk/tools/androidviewclient-2.3.24.jar/com/dtmilano/android/viewclient$py.class", line 1864, in…
Ehsan
  • 4,334
  • 7
  • 39
  • 59
0
votes
1 answer

Android Nexus 10 AOSP build AndroidViewClient

I finally managed to successfully build a Nexus 10 image (full_manta-userdebug) with Google Mobile Services installed but unfortunately, I'm unable to use my MonkeyRunner script that uses AndroidViewClient. It crashes out of the script with the…
0
votes
0 answers

AndroidViewClient Settings > Developer Settings checkbox issues

I don't know if anyone else has run into this problem, but when I try to use AndroidViewClient/Monkeyrunner to click on the checkboxes for the "Stay Awake" and "Allow mock locations" options, they do not persist after navigating away from the…
Android Noob
  • 3,271
  • 4
  • 34
  • 60
0
votes
0 answers

AndroidViewClient waiting for wi-fi issue

I'm in the middle of automating the Google Registration and I'm running into an issue... As part of the registration, you need to sign into Wi-Fi and then wait until you are connected. After entering the Wi-Fi credentials, I do a wait in a while…
Android Noob
  • 3,271
  • 4
  • 34
  • 60
0
votes
1 answer

AndroidViewClient: content is not allowed in trailing section

I installed AndroidViewClient via Git on my Windows Vista machine at home and I setup the path variables and ran the check-imports.py script to make sure everything was ok. Next, I tried to run the settings.py script from the /examples folder and…
Android Noob
  • 3,271
  • 4
  • 34
  • 60
0
votes
1 answer

monkeyrunner import os arrayindexoutofboundsexception

I have the Pythonv2.6.5, Jythonv2.5.3 and ADT22.01 installed but for some reason, whether its in a python script or just from the monkeyrunner command-line, when I simply type in import os, I get an ArrayIndexOutofBoundsException. This is being run…
Android Noob
  • 3,271
  • 4
  • 34
  • 60
0
votes
1 answer

Android SDK MonkeyRunner can't make connection (NullPointerException)

No matter what I do, I can not seem to get MonkeyRunner to connect to the emulator, even though it's running and adb shows that it is available: C:\Users\ADMIN\Documents\android\sdk\platform-tools>adb devices List of devices attached …
0
votes
1 answer

Does MonkeyTalk support localization in Android?

When I record an action (for eg: button click) MonkeyTalk records the button text as a String so it doesnt work when I change the language on the device to non-English. Eg: Button nein tap works fine in German language but doesn't work when I…
AndroidDev
  • 5,193
  • 5
  • 37
  • 68
0
votes
1 answer

AndroidViewClient doesn't get view's coordinates

i'm working with AndroidViewClient to find EditText and Buttons to push with monkeyrunner. The problem is that AndroidViewClient isn't able to get the coordinates, in pixels, of theses views. The results says the next: …
user2366903
  • 15
  • 2
  • 5
0
votes
1 answer

How to find out idle application in android?

We are trying to automate the testing of android phones. We want to run a benchmark application in android through monkeyrunner/adb, at the end of test how can i detect the test is complete or not through adb/monkeyrunner. Is there any command to…
Premjith
  • 1,128
  • 1
  • 11
  • 21
0
votes
1 answer

android monkeyrunner waitForConnection hang forever

My environment consist of Ubuntu 13.04, Optimus Q2 with ics. when I run the following code, it prints 0 but never 1 #! /usr/bin/env monkeyrunner # Imports the monkeyrunner modules used by this program from com.android.monkeyrunner import…
kim taeyun
  • 1,837
  • 2
  • 24
  • 49
0
votes
1 answer

Python: ImportError: No module named logging

I am trying to import logging in Monkeyrunner environment but it always respond "ImportError: No module named logging" ?
0
votes
2 answers

Error passing uiautomator dump in viewclient.py

I am getting below exection when running viewclient. I am running this on Emulator using android-17 api. viewclient = ViewClient(device, serialno) File…
user1819441
  • 127
  • 2
  • 12