Make fullReset clear app on session stop as well

This commit is contained in:
Sam Park
2014-02-04 09:45:09 -08:00
parent 736b72bda2
commit 72ac77544b
4 changed files with 28 additions and 2 deletions

View File

@@ -318,6 +318,18 @@ Android.prototype.requestXmlCompression = function (cb) {
Android.prototype.stop = function (cb) {
this.shuttingDown = true;
if (this.opts.fullReset) {
logger.info("Removing app from device");
this.uninstallApp(function (err) {
if (err) {
// simply warn on error here, because we don't want to stop the shutdown
// process
logger.warn(err);
}
});
}
if (this.adb) {
this.adb.goToHome(function () {
this.shutdown(cb);