When testing Steeplechase I often want to run tests on the same machine as the test harness. I thought it would be handy to have a "local" DeviceManager implementation instead of having to run Negatus on localhost. It turns out to be not that hard to implement most of the DM API this way, so I did it. The nice thing is that it's way faster than using Negatus on localhost. There are a few things I didn't implement (mostly in getInfo), and a few that I intentionally stubbed out because they don't make sense (the installApp etc functions), as well as a few where the semantics of the API are unclear and I didn't do the work to look at the other implementations.
Interesting. We have a patch that does something similar for desktop B2G in the Gaia UI tests. In our case we created a file manager to abstract mozdevice when the target is not a device. See bug 984340.
Ah, cool! I just whipped this up quickly yesterday to try it out. The neat thing is that I can drop this into Steeplechase with just a few lines of code (instantiate DeviceManagerLocal instead of DeviceManagerSUT) and I don't have to change the rest of the harness to accomodate. jmaher and I had actually talked about an approach like this for better unifying the desktop and remote harnesses: run everything through a devicemanager class, just the desktop one works directly on the local system.
I have a python version of devicemanager: http://people.mozilla.org/~jmaher/sutagent/test-agent.py.txt pick and choose the best parts :)
I forgot all about that!
You need to log in before you can comment on or make changes to this bug.