testing ajax in phonegap