Field for URL entry in iOS different from Android

Mobile Testing, Android App Testing.
gilbar16
Posts: 109
Joined: Wed Mar 26, 2014 6:23 pm

Field for URL entry in iOS different from Android

Post by gilbar16 » Thu Oct 15, 2015 6:33 pm

Ranorex version 5.4.2
For iOS:
Ranorex Services v 2.1.0
RxBrowser v 2.1.2

For Android:
Ranorex Services v 1.8.3
RxBrowser v 1.8.5

I tried to run the scripts that work in iOS device in an Android device and finding out that the field where you enter the URL or web address of your AUT is different in Android device.

What needs to make this generic for both iOS and Android?

The Path I have for iOS is:
?/?/text[@accessibilitylabel='Url']
or
/mobileapp[@title='ranorex.RxBrowser']/form/?/?/text[@accessibilitylabel='Url']

The Path I have for Android is:
.//container[@rid=UrlHeader']/text[@accessibilitylabel='Url']
or
/mobileapp[@title='ranorex.RxBrowser']/form//container[@rid='UrlHeader']/text[@accessibilitylabel='Url']


Thanks.
Gilbert

gilbar16
Posts: 109
Joined: Wed Mar 26, 2014 6:23 pm

Re: Field for URL entry in iOS different from Android

Post by gilbar16 » Thu Oct 15, 2015 10:06 pm

Sorry, I misunderstood what I saw in the Ranorex Demo/Webinar where one script recorded in Android also executed successfully in iOS or vice versa.

Now, I found out that it is not recommended to share repository for both iOS and Android due to differences in their native webviews. So there are more differences I noticed while checking out the other objects/elements.

Test scripts can still work for both iOS and Android devices but lots of experiments to be done with the Ranorex XPath to identify objects correctly for both devices.