cordova mock initializes document