i am evaluating Ranorex for automated tests of Qt-application under Windows XP.
The accessibilty plugin works fine, but every control (buttons, ipnut fields, ...) is recognized under multiple paths.
So i can see, at least, 4 different paths to the same control. I tried to create one repository with the shortest path of all controls. When i use the recorder, it creates its own elements with long paths. Looks like its using 'depth first search' in the object tree (as it appears in the spy), and returns the first found path to the element, which is not the shortest. So i have to replace all the paths by hand, and this takes hours and therefore is not suitable for us.
Is it possible to let the recorder search for the shortest path (like 'breadth first search') of the element in the objecttree, or to force the recorder to use the paths that are already defined in the repository?
Ranorex Spy, Recorder, and Studio.
2 posts • Page 1 of 1
- Support Team
- Site Admin
- Posts: 12169
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
Could you please explain that a little more in detail? E.g. could you post the repository? What Ranorex version do you use?CuTe wrote:The accessibilty plugin works fine, but every control (buttons, ipnut fields, ...) is recognized under multiple paths.
RanoreXPath always performs a breadth-first search. However, when you track an item, Ranorex performs a FindFromPoint operation which tries to get the best (=smallest) element at that point and then creates the RanoreXPath for it. Maybe this is what you experience?
In general, the Ranorex repository tries to use the items that are already in the repository. However, if the paths are not very similar, e.g. if the have a different number of levels in it or use special operators like "//", Ranorex cannot automatically determine that two paths match. Then the repository generator uses the "safe" alternative and creates a new repository item.