Ask a Question

iOS mobile app vs web links

slecault
Contributor

iOS mobile app vs web links

I am testing a mobile app available in both Android and iOS.  The app contains web views but also quite a few "web links".

 

When I touch one of these "web links" the link opens in a distinct browser. 

 

With Android, I wait a few seconds, take a screenshot, and then send a "hardware back button" which returns me to the mobile app.

 

With iOS, the browser opens with the same page as Android.  The problem is how do I tell this browser to go back to my app since I cannot automate stuff outside my tested app.

 

The objective here is to see that the embedded links point to the appropriate web pages.

Win10 / Server 2016 - Testing Delphi Application, Dynamic AX, Web, XamarinForms Mobile app iOS and Android over Appium, TC 15 and TestExecute
8 REPLIES 8
AlexKaras
Champion Level 3

Hi,

 

Really good question...

SmartBearBrowser (https://support.smartbear.com/testcomplete/docs/app-testing/web/mobile/real-devices.html) is the first thing that came to my mind... If it is possible to set it as a default browser for your iOS device then I hope that you should be able to control both, the browser and your application and that you will be back to your application after closing the browser.

 

Another link that might provide you with some ideas is https://support.smartbear.com/testcomplete/docs/app-testing/mobile/ios/how-to/slide-over.html

Regards,
  /Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================

My readings and searches so far indicate that iOS does not want you to change the default browser (or other default programs).

As soon as we step outside the tested app, the control is lost...

Win10 / Server 2016 - Testing Delphi Application, Dynamic AX, Web, XamarinForms Mobile app iOS and Android over Appium, TC 15 and TestExecute

Hi,

 

Sounds not good... Unfortunately, I am not working with iOS and thus cannot verify..., so just an idea - does pressing Back button returns you back to your application?

If it does, you may try

<iOSDevice>.PressButton(mbkBack)

 

Does it help ?

Regards,
  /Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================

I do not know if the "back" button would work on all devices, but I get the following error:

"No instrumented application is running on the device."

Because my app started a "browser" which is now in foreground...

 

 

Win10 / Server 2016 - Testing Delphi Application, Dynamic AX, Web, XamarinForms Mobile app iOS and Android over Appium, TC 15 and TestExecute

Hi,

 

Hm... It was my expectation that Device methods do not depend on the tested application...

No other idea except asking Support via the https://support.smartbear.com/message/?prod=TestComplete form.

 

P.S. Will appreciate it if you let us know whether you find solution with Support.

Regards,
  /Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================

I will open a ticket in January after the holidays...

Thanks

Win10 / Server 2016 - Testing Delphi Application, Dynamic AX, Web, XamarinForms Mobile app iOS and Android over Appium, TC 15 and TestExecute
slecault
Contributor

Answer from my support case: "Apple doesn't allow changing Safari to another browser, so it's not possible that your links are being opened in the SmartBear browser for iOS."

 

I will try to get some information within the app with our dev team to maybe have a property that would contain the web link. At least some sort of basic verification could be done during the automated testing.

Win10 / Server 2016 - Testing Delphi Application, Dynamic AX, Web, XamarinForms Mobile app iOS and Android over Appium, TC 15 and TestExecute

Hi,

 

Thank you a lot for the update.

 

> Apple doesn't allow changing Safari to another browser

🙂 (Y)
Reminded me a holy indignation with IE been "too integrated" into Windows...

What is allowed to Jupiter, then the bull is not allowed...

Regards,
  /Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================
cancel
Showing results for 
Search instead for 
Did you mean: