Question

Is there a way to automatically test android apps performance, like the time, needed by an app to load itself and become ready for user's interaction in android?

Was it helpful?

Solution

The one useful thing to do app performance automation is dumpsys that is described in this talk: https://www.youtube.com/watch?v=Qfo5fdoXrTU

enter image description here

Also there is a nice log output for the app start time, this is a quote from the docs:

From Android 4.4 (API level 19), logcat includes an output line containing a value called Displayed. This value represents the amount of time elapsed between launching the process and finishing drawing the corresponding activity on the screen. The elapsed time encompasses the following sequence of events:

Launch the process. Initialize the objects. Create and initialize the activity. Inflate the layout. Draw your application for the first time. The reported log line looks similar to the following example:

ActivityManager: Displayed com.android.myexample/.StartupTiming: +3s534ms

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top