diff --git a/lib/commands/app-management.js b/lib/commands/app-management.js index 47554987..6500fa75 100644 --- a/lib/commands/app-management.js +++ b/lib/commands/app-management.js @@ -81,8 +81,10 @@ commands.activateApp = async function activateApp (appId) { 'am', (apiLevel < 26) ? 'start' : 'start-activity', '-a', 'android.intent.action.MAIN', '-c', 'android.intent.category.LAUNCHER', - // FLAG_ACTIVITY_REORDER_TO_FRONT | FLAG_ACTIVITY_BROUGHT_TO_FRONT | FLAG_ACTIVITY_NEW_TASK - '-f', '0x10420000', + // FLAG_ACTIVITY_NEW_TASK | FLAG_ACTIVITY_RESET_TASK_IF_NEEDED + // https://developer.android.com/reference/android/content/Intent#FLAG_ACTIVITY_NEW_TASK + // https://developer.android.com/reference/android/content/Intent#FLAG_ACTIVITY_RESET_TASK_IF_NEEDED + '-f', '0x10200000', '-n', await this.adb.resolveLaunchableActivity(appId), ]); this.log.debug(stdout); diff --git a/package.json b/package.json index 202ad674..35f83467 100644 --- a/package.json +++ b/package.json @@ -38,7 +38,7 @@ "@appium/base-driver": "^8.5.2", "@appium/support": "^2.58.0", "@babel/runtime": "^7.0.0", - "appium-adb": "^9.5.0", + "appium-adb": "^9.6.0", "appium-chromedriver": "^5.0.1", "asyncbox": "^2.8.0", "axios": "^0.x",