How to avoid frequent repository changes?

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
sunil.pandey
Posts: 11
Joined: Fri Jul 03, 2015 5:35 pm

How to avoid frequent repository changes?

Post by sunil.pandey » Fri Jul 10, 2015 7:08 am

Hi,

Please help me to understand below mentioned query:
As per the recommendation Ranorex path is best way to identify the controls/elements
but in case if xpaths keeps changing frequently, Ranorex won't be able to identify controls,
Actually we've faced same issue in Selenium automation.
Please suggest how to make robust repositoy where it can identify control in case of small changes like <tr>, <tb>, index etc..

Thanks & Regards,
Sunil

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 3937
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: How to avoid frequent repository changes?

Post by odklizec » Fri Jul 10, 2015 7:30 am

Hi,

There is unfortunately no "magic" and always working solution to frequently changing xpaths. The best you can do is to find unique identification attributes, which are persistent. If there are no such attributes in your tested apps, you will have to use relative paths and functions described here:
http://www.ranorex.com/support/user-gui ... xpath.html

In many cases, you can find an element by first identifying completely different element and then by using relative paths and functions navigate to the correct one.

I would recommend you to read this article:
http://www.ranorex.com/blog/automated-t ... ynamic-ids

and watch these xpath related screencasts:
http://www.ranorex.com/support/screencasts.html#c2667
http://www.ranorex.com/support/screencasts.html#c2669
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration