Closing existing app doesn't work

Observed behavior:
Whenever running a test script which uses keyword Mobile.startExistingApplication Katalon Studio fails to execute the keyword Mobile.closeApplication()
The log says “Close app successfully” but the app remains open on the last screen before Mobile.closeApplication() was executed.

I was able to reproduce this behavior on devices running on Android 8, 9 and 10.
I’ve also tested with several versions of Katalon Studio (7.1.2 and 8.0.0).

Test was executed on:
WIN 10 build 1903
Appium 1.14.0

Keep in mind this behavior only occurs when using keyword Mobile.startExistingApplication, when using keyword Mobile.startApplication the app is closed correctly after Mobile.closeApplication() is executed.

Expected behavior:
Existing app is closed after keyword Mobile.closeApplication() is executed.

3 Likes

I can confirm that I’m able to reproduce this issue with:

Mac OS 10.15
Katalon Studio 7.0.6
Android 8.1.0
Appium 1.15.1

I can confirm that this bug is still present in KSE 7.5.2.
Regards
Dan

Dears,

The Bug still exist on latest version of Katalon Studio version 8.1.0, as the close application doesn’t work and the start application doesn’t start with new session

any advice please …

1 Like

Hi all,

I try with your above steps and see that the keyword Mobile.closeApplication(FailureHandling.STOP_ON_FAILURE) does NOT close the application after open the application. However, I found a way to close the application and it works from my side:

Steps

  1. Import need package: This package is used to get appium driver from Katalon
    import com.kms.katalon.core.mobile.keyword.internal.MobileDriverFactory

  2. Get current driver after open app:
    Mobile.startExistingApplication(‘com.dencreak.dlcalculator’)
    driver = MobileDriverFactory.getDriver()

3.Perform your steps with automation:
// your customize

4.Quit your app by below comment
driver.resetApp()

1 Like

Hi all,

We will put this issue in our backlog and we will get you updated when it’s ready.

Thanks,
Nam Nguyen.

1 Like

I can confirm this bug still exist on Katalon Studio ver 8.3.5 build 208.

Windows 11
Android 9 (emulated)
Appium 1.22.3

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.