Integrating UI Performance into your testing practices guarantees interaction with your applications satisfies users’ demands.
Showing posts with label performance. Show all posts
Showing posts with label performance. Show all posts
Wednesday, June 28, 2017
Analyzing Android UI Performance
Labels:
android,
AndroidViewClient,
performance,
uiautomator,
unit test
Sunday, April 02, 2017
Testing Android UI Performance
In a previous post, we were analyzing how to Detect memory leaks on Android apps. That is a very important step in testing and analyzing your application's performance.
Once you are done, you may want to sure that user interactions with your app are smooth, and they run at a consistent 60 frames per second mark.
We will explain here how AndroidViewClient/culebra can help automating and simplifying some steps that usually require manual interaction. In such way, you can measure UI performance, and produce charts that will help you understand and locate the problems
Latest AndroidViewClient/culebra versions have introduced the ability to plot some metrics from your device or emulator directly. The Dumpsys module obtains and parses dumpsys information to greatly facilitate its usage converting it to objects.
This second chart is then obtained by running OPEN RECYCLER VIEW from the same example.
Once you are done, you may want to sure that user interactions with your app are smooth, and they run at a consistent 60 frames per second mark.
We will explain here how AndroidViewClient/culebra can help automating and simplifying some steps that usually require manual interaction. In such way, you can measure UI performance, and produce charts that will help you understand and locate the problems
Latest AndroidViewClient/culebra versions have introduced the ability to plot some metrics from your device or emulator directly. The Dumpsys module obtains and parses dumpsys information to greatly facilitate its usage converting it to objects.
def __plot_dumpsys_gfxinfo(self, pkg):
self.plot.append(Dumpsys(self.device, Dumpsys.GFXINFO, pkg, Dumpsys.FRAMESTATS)) \
.plot(_type=Dumpsys.FRAMESTATS)
self.plot.append(Dumpsys(self.device, Dumpsys.GFXINFO, pkg, Dumpsys.FRAMESTATS)) \
.plot(_type=Dumpsys.FRAMESTATS)
This helper method (that can be found in AndroidViewClient/culebra tests) appends to the plot the framestats information obtained from dumpsys gfxinfo for the given package pkg. Then it creates the histogram chart.
This first chart shows the information obtained by running OPEN LIST VIEW from Automated Performance Testing after scrolling the lists.
The vertical lines indicate 60 and 30 FPS respectively.
In this case, the improvements made by the RecyclerView are obvious.
As always, you can find more information about AndroidViewClient/culebra in its wiki at https://github.com/dtmilano/AndroidViewClient/wiki, about CulebraTester at http://culebra.dtmilano.com/ and https://github.com/dtmilano/CulebraTester-public/wiki and if you have any question you can ask in Stackoverflow using http://stackoverflow.com/questions/tagged/androidviewclient.
Labels:
adb,
android,
AndroidViewClient,
culebra,
gui,
monkeyrunner,
performance,
tests
Subscribe to:
Posts (Atom)


