Forum Discussion
HKosova
Alumni
14 years agoHi Alex,
From what I've observed, the problem seems to be in the recorded identification properties of the "Air" and other "blue" menu links in Name Mapping (the object repository). Specifically, the namePropStr property includes the URL link, but the URL of these links changes dynamically when you place the mouse over them. For example, the original URL of the "Air" link that is specified in the web page source is /flight?int=GNAVBOOKAIR, but when you place the mouse over it, it becomes /flight?int=GNAVBOOKAIR&disc=&ss=0&cid=&companyName=&memberName=.
The recorded namePropStr property value includes this final dynamically generated URL. But at the run time, the link's initial URL is different, so the link cannot be identified.
To resolve the problem, you need to edit Name Mapping and either remove the namePropStr property from the links' identification properties, or replace the dynamic parameters in the namePropStr value with the * wildcard -- as it's shown in the attached screenshot.
To quickly find the needed objects in Name Mapping, you can do the following:
* Open the Object Spy and select the "Air" link.
* Right-click somewhere within the property list and select Show Object in Name Mapping Editor.
Then, repeat these steps for other links (Hotel, Car, etc.)
Please let me know if this is the case, and whether this suggestion helps.
By the way, you may be interested in watching our webinar on the subject:
Creating Reliable Tests For Dynamic Objects with Name Mapping
It describes hints and tips for selecting stable identifiers for the objects in web applications.
From what I've observed, the problem seems to be in the recorded identification properties of the "Air" and other "blue" menu links in Name Mapping (the object repository). Specifically, the namePropStr property includes the URL link, but the URL of these links changes dynamically when you place the mouse over them. For example, the original URL of the "Air" link that is specified in the web page source is /flight?int=GNAVBOOKAIR, but when you place the mouse over it, it becomes /flight?int=GNAVBOOKAIR&disc=&ss=0&cid=&companyName=&memberName=.
The recorded namePropStr property value includes this final dynamically generated URL. But at the run time, the link's initial URL is different, so the link cannot be identified.
To resolve the problem, you need to edit Name Mapping and either remove the namePropStr property from the links' identification properties, or replace the dynamic parameters in the namePropStr value with the * wildcard -- as it's shown in the attached screenshot.
To quickly find the needed objects in Name Mapping, you can do the following:
* Open the Object Spy and select the "Air" link.
* Right-click somewhere within the property list and select Show Object in Name Mapping Editor.
Then, repeat these steps for other links (Hotel, Car, etc.)
Please let me know if this is the case, and whether this suggestion helps.
By the way, you may be interested in watching our webinar on the subject:
Creating Reliable Tests For Dynamic Objects with Name Mapping
It describes hints and tips for selecting stable identifiers for the objects in web applications.