This is a migrated thread and some comments may be shown as answers.

FindLogic Ignores Recording Element Added to Repository

1 Answer 20 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Kimberlee
Top achievements
Rank 1
Kimberlee asked on 20 Feb 2014, 01:08 AM
I'm currently running into an issue where Test Studio will not record elements added ot the repository before and/or after adding them. This occurs most frequently with continue buttons and radio dials which are javascript driven. The tool records them with generic labels such as continuespan, continuespan(), span1, etc.

I noticed that when attempting to edit the element, findlogic is capturing the div id and tagindex. The problem occurs when trying to re-use the element in other tests involging different parameters, causing the test to fail because for some reason the element cannot be located. I also noticed that when recording new tests with different parameters and selecting the same continuebutton, the span for the tagindex changes.

I have tried rearranging the order in which Test Studio finds elements, adding the "class" tag and no luck. It continues to pick up the div id and tagindex. Currently, we do not have individual label ids on all the elements in our system but before I investigate that route, I wanted to inquire there is a solution through the tool that can help alleviate this problem that I'm unaware of?

Screenshots are attached if needed.

1 Answer, 1 is accepted

Sort by
0
Cody
Telerik team
answered on 24 Feb 2014, 11:10 PM
Hello Kimberlee,

Your screen shots did not make it through. Keep in mind we only accept file types zip, rar, ace, jpg, gif, css, png.

The tool records them with generic labels such as continuespan, continuespan(), span1, etc.

Those names are the "friendly name's" given to the element. They're much like a variable in a problem. The name could be anything as it doesn't effect how the test runs. What does matter is the find expression that is attached to that name. That's what Test Studio uses for finding the target element during test execution.

The problem occurs when trying to re-use the element in other tests involging different parameters

How are the parameters different?

It continues to pick up the div id and tagindex

Test Studio will use TagIndex as a last resort when it can't find anything better that would be unique. The problem with TagIndex is that it's brittle. If a new element shows up in between runs (or an element is removed between runs) then the TagIndex will be wrong e.g. it was recorded as TagIndex 47 but should have been 46 or 48 in follow up runs.

I wanted to inquire there is a solution through the tool that can help alleviate this problem that I'm unaware of?

To be able to help you figure this out better we need to see an example of an actual test failure that is caused by this problem. Go to Step Failure Details, find and click Export, then attach the generated .zip file to this support ticket. That will give us valuable information for diagnosing and fixing element not found failures.

Regards,
Cody
Telerik
The New Release of Telerik Test Studio Is Here! Download, install,
and send us your feedback!
Tags
General Discussions
Asked by
Kimberlee
Top achievements
Rank 1
Answers by
Cody
Telerik team
Share this question
or