SOMCA / hot-pepper

An automated test bench for monitoring the power consumption of mobile apps
GNU Affero General Public License v3.0
0 stars 0 forks source link

Correlate both scenario and lightpowertool timelines #5

Closed k0pernicus closed 8 years ago

k0pernicus commented 8 years ago

To know which method is consuming more or less energy, we have to correlate both scenario and output (from lightpowertool) timelines.
I think that can be done by separate scenarios from an existing feature (for Calabash especially), and just write a single scenario per Calabash feature.
With this solution, as soon as a feature/scenario is over, lightpowertool will stop his execution.
Unfortunately, a grained approach is not possible with existing tools...

rouvoy commented 8 years ago

Instead of instrumenting the app, can't we instrument the scenario to automatically log actions on the app with timestamps in order to make such a correlation a posteriori?

k0pernicus commented 8 years ago

One solution is to output a basic text file for each Calabash feature, which contains the name of the method called and the timestamp of this call. With this file, as the tests are complete, it can be possible to correlate each measure with the good action...

The second option is to build an other software which receive Calabash and LightPowertool calls to merge them into a single file - using NodeJS for example.

k0pernicus commented 8 years ago

The second option has been choosen.
I implement a web server with Python to communicate with LightPowertool and Calabash - it's working and merge efficiently both timelines.