No Nonsense direct loading!
Monkey is the program that comes with the Android system, location:/sdk/tools/lib/monkey.jar,monkey.jar is executed by a monkey shell script, the script path is/sdk/tools/bin/monkey;
Monkey can therefore be executed directly in the shell environment. (Note configuration environment)
Official shipments can be viewed directly from adb shell monkey-help:
Monkey-p com.youku.phone--ignore-crashes--ignore-timeouts--ignore-security-exceptions--kill-process-after-error -v-v-V--throttle 50000 >/mnt/sdcard/monkeypack.log 2>&1 &
Com.youku.phone is Youku's package name you want to test what app you can download a registration viewer
You can also adb shell
LS Data/data//This seemingly requires mobile jailbreak
-P is a limitation for testing a given app, monkey only runs the package after-p, and if no-p,monkey will run all apps randomly by default
adb shell monkey-p Comg.android.mms 100//means randomly sending 100 random events to the SMS app
-V is the default level for the level of feedback information is 0
adb shell monkey-p com.android.mms-v 100//Can compare the details of the printed information under-V-V and-v-v-V.
Monkey test will automatically stop in the following three scenarios during execution:
1. If monkey is qualified to run on one or several specific packages, it will monitor and block attempts to move to other packages.
2. If the application crashes or receives any runaway anomalies, the monkey will stop and error.
3. If the application produces an error that the application does not respond (application not responding), the monkey will stop and make a mistake.
--ignore-crashes--ignore-timeouts--ignore-security-exceptions--kill-process-after-error
These are actually let Mongkey encounter similar crash, timeout also can run down normally
--throttle < milliseconds > This is the unit of extended reaction time is milliseconds specific can change the digital experience yourself
/mnt/sdcard/monkeypack.log 2>&1 & Generate a Monkeypack.log file on your phone sdcard and run it out to see the results.
Stop Monkey
PS com
Kill <monkey pid>//ps com with the. Monkey End of the PID
Monkey Test Summary