Apply changes to the xpath during creation
Posted: Mon Sep 01, 2014 2:54 pm
Hello,
I am trying to create automated tests for a web application with Ranorex and I have the following problem:
I want to use the same recording modules in the tests for multiple browsers, but the dom tree varies based on what browser is used. For example, a given element is in the third body tag in one browser and in the first body tag in another browser. What I do now is manually replace the .../body[pos()=1]/... with .../?//... within the xpath so that the element is found in both browsers.
Is there any way to automate that process, so that the above mentioned replacement is executed within the process where the xpath is created while tracking the element, just like you can edit the path weights?
I am trying to create automated tests for a web application with Ranorex and I have the following problem:
I want to use the same recording modules in the tests for multiple browsers, but the dom tree varies based on what browser is used. For example, a given element is in the third body tag in one browser and in the first body tag in another browser. What I do now is manually replace the .../body[pos()=1]/... with .../?//... within the xpath so that the element is found in both browsers.
Is there any way to automate that process, so that the above mentioned replacement is executed within the process where the xpath is created while tracking the element, just like you can edit the path weights?