0

I am using Codeceptjs framework with Appium helper for my UI automation. I want to go to Device home on IOS platform and then navigate back to App. I am using browserstack to run my scripts. I have tried closeApp, but this fails the test on browserstack and closes the session. sendDeviceKeyEvent(3) works only on Android. Please help. :(

I am expecting to be on home screen of device or put app to background and then launch the app again.

anusha
  • 1

1 Answers1

0

There is an alternative way to keep the app running in the background.

You can simply open the Safari Browser as it comes pre-installed in every iPhone device by the command:

driver.activate_app("com.apple.mobilesafari");

Once Safari is launched you add configure a wait time. Then you can again relaunch your running app from the background by the following:

driver.activate_app("YOUR.APP-ID"); 

So this method will atleast help you launch the app from running in the background.