Forum Discussion
7 Replies
- AlexKaras
Champion Level 2
Hi Ulrich,
Any more details please?
Is this somehow related to TestComplete?
- ucuberOccasional Contributor
Hi Alex,
most of the time we use CSS selectors for accessing webelement. We like it more than the NameMapping, especially because we have a lot of dynamic elements. As it can be seen in the posts before we use python to do the work, what works very well
When we access a WebElement there often comes a SavaArrayWrapper or DispatchWrapper object. I've read a lot of stoff about it and did a lot of dir-ing into the objects. But up to now I did not find a way to analyse the api of such an object related to the attributes or methods they wrap. So it is a lot of try and error, what is a little bit frustrating - ok, very frustrating ;-)
So if you or anyone has an idea how to identify the wrapped apis of the objects I would be more than happy.
Regards
Ulrich
- AlexKaras
Champion Level 2
Hi Ulrich,
Some example will help... but my current guess is that you are talking about .QuerySelector() and .QuerySelectorAll() methods provided by TestComplete.
I did not use them (and this seems to be not mentioned in the documentation), but I think that they behave exactly like the .EvaluateXPath() and .FindChildByXPath() methods. I.e.: if the found web element can be matched to the object from the Object Browser, then the matched object is returned. Otherwise, native DOM element is returned.
If the above is correct, then the objects that you are talking about should be either native objects/interfaces provided by the given web elements (and thus you should read relevant DOM documentation) or are provided by Python itself (and thus should be addressed in Python's docs). Though I really doubt about latter and tend to think that this is something from the native DOM area...