Writing an app for Android takes a lot of work. One of the greatest pains developers suffer from is the testing process, which many do badly or not at all. Why? Testing sucks - but it's a necessary evil.
In this class, you'll learn about test methods available to developers today, in particular Monkey, the user interface testing tool. You'll learn why Monkey is such an effective tool, and how to use it to test your own apps. You'll also learn about the limitations of Monkey, especially when it comes to making sure your app runs on any Android device. Finally, you'll learn about Apkudo, a testing solution that lets developers see how their apps install, execute, and perform on every (yes, every) Android device, assuring interoperability and customer satisfaction.
Testing doesn't have to suck. We'll show you why.
13. MONKEYvVS onkey
Runner
Monkey
s
M
MONKEY RUNNER
• Monkey is for randomized testing, and runs on
the device
• Monkey Runner is for scripting your own tests,
and runs on a laptop / desktop
• In fact, Monkey Runner uses Monkey internally
20. Ac:vity
life-‐cycle
errors
ACTIVITY LIFE CYCLE
ERRORS
• Monkey performs unexpected activity life-
cycle actions
• Example: Shazam: Unable to pause activity
• Resolution: Become tiresomely familiar
with the Android activity life cycle.
21. MULTI-DEVICE Monkey
Mul:-‐device
MONKEY
• Monkey is really good at testing across
multiple devices:
• Correct Market permissions
– appropriate-architecture native code, eg armv7
• Unexpected hardware properties
• “Weird” hardware failures
22. Mul:-‐device
Monkey
CORRECT MARKET
FILTERS
• OpenGL ES version and features
• Dependencies on system libraries
• Incorrect or missing minSdkVersion
23. Unexpected
hardware
proper:es
UNEXPECTED HARDWARE
PROPERTIES
• The device has an unexpected hardware
feature (e.g. a strange screen resolution)
• Examples: RDefense Free, Zombie Killer
• Best resolution: Test on multiple devices