Android M Testing with Doze and App Standby

Adventures in QA - Android M Testing with Doze and App Standby

You probably all know that Google has started with the rollout of Android M (Marshmallow). Android app developers and testers must know the new features that are coming with the latest version of Android M. Next to the brand new permission system, Android M also introduces Doze and App standby to save battery.

If a user leaves a device unplugged and stationary for a period of time, with the screen off, the device enters Doze mode. In Doze mode, the system attempts to conserve battery by restricting apps’ access to network and CPU-intensive services. It also prevents apps from accessing the network and defers their jobs, syncs, and standard alarms.
Periodically, the system exits Doze for a brief time to let apps complete their deferred activities. During this maintenance window, the system runs all pending syncs, jobs, and alarms, and lets apps access the network. (Source: Google documentation)

In order to be sure that your app is able to handle Doze and app Standby, Google provided some documentation on that. Here are the steps to make sure your app handles Doze (instructions copied from the documentation):

Testing your app with Doze

You can test Doze mode by following these steps:

Read more