Automated testing

583 views
Skip to first unread message

Chris Bushell

unread,
Jan 17, 2011, 5:27:42 PM1/17/11
to phonegap
Hi there. Can anyone offer some advice on automated testing of
Phonegap applications? I'm looking for something which offers Selenium/
Webdriver capabilities which is able to run on iPhone/Android devices
or the simulator/emulator. I'd like to be able to programmatically
click through my app and make assertions on the state of the
application to ensure it's working correctly.

We're finding that desktop browser based testing of our application is
not enough to ensure a good experience on the device itself i.e. the
application looks good in a desktop browser but doesn't look good when
running either iPhone/Android, or both.

So far, I've looked at Robotium and Robolectric as well as the
standard Android testing framework, but they all seem to rely on a
native interface and wont work with Phongegap. I'm looking at Sikuli
as an alternative which uses image recognition, which I think would
probably work with Phonegap.

What are other people using for their automated testing?

Regards,
Chris.

Nick McCloud

unread,
Jan 18, 2011, 4:33:57 AM1/18/11
to phonegap
I use Fake which drives Safari to test functionality and have not been
badly bitten yet (fingers crossed) with something that works on
desktop but not on mobile. This can't test on device functions though
so I use test stubs. I can then write another set of tests that tests
the test stub responses against actual on device api's.

I can't imagine that there are any programs that can check that 'it
looks good' on the mobile device. The performance between a 3G and a
3GS and a iPhone 4 are so different that some apps are unusably slow
but still work on a 3G but gorgeous on an iPhone 4. Only a live human
being can really check that.

Chris Bushell

unread,
Jan 18, 2011, 5:03:54 PM1/18/11
to phonegap
Thanks for the info Nick. You might be interested in Ripple, a chrome
plugin which implements the phonegap api for you (http://
ripple.tinyhippos.com/). I've also been looking at Sikuli which allows
for junit style tests using image recognition (http://sikuli.org/).
I'm thinking that this could be used for basic sanity checking of the
ui in the simulator/emulator before passing a build over for manual
testing, which I agree will be needed anyway.

Chris.
Reply all
Reply to author
Forward
0 new messages