I'm using monkey command to do some stress testing on my app. But i want to test it more with respect to screen orientations to detect and capture some heapupdates while changing orientations. I searched all over android official site about monkey commands/arguments which will do screen orientations while running on any app/activity. But no luck and thought of asking professionals like you.
If idea on this, please let me know.
Monkey has a number of undocumented options, including
--pct-rotation
. Add that switch to your command and watch your screen rotate like it's possessed by demons:Up to (including) adb version 1.0.31:
Since adb version 1.0.32:
Look in the processOptions() method of the monkey command to see all of the supported options: https://android.googlesource.com/platform/development.git/+/master/cmds/monkey/src/com/android/commands/monkey/Monkey.java
Look at the constructor for the MonkeySourceRandom class to see the default percentages for all of the event types. These are the current values in the master branch at the time of this post. Note that the default for rotation is 0:
https://android.googlesource.com/platform/development.git/+/master/cmds/monkey/src/com/android/commands/monkey/MonkeySourceRandom.java