Added test for window.cordova.plugins != undefined