Forum Discussion

lea_lindemann's avatar
lea_lindemann
Occasional Contributor
13 years ago

Object spy problems with dynamic website

Hi everyone,



I'm working with TestComplete 9, firefox and a dynamic website. The Object Spy won't spy any child objects of a Document (e.g. buttons of the website). On static html pages the object spy works just fine.



Funny thing is, that in the Object Browser I can inspect child objects of the Document which the spy does not work on. Still the objects do not have all properties I would expect them to have. For example a table is missing the RowCount and ColumnCount properties an the method Cell(x,y).



Project properties:

Open Applications > Web Testing > Tree model = Tree

Open Applications > MSAA > List of accepted windows: checked *



I guess I have missed some important settings.





Glad for any help,

Lea
  • I think this happens when zoom is more then 100%






    TestComplete requires that the browser zoom is set to 100% to correctly identify web page elements and their position on web pages.



    Firefox uses 100% by default. If you changed the zoom manually, you can do one of the following to restore it:





    • Press CTRL + 0.






    http://support.smartbear.com/viewarticle/28079/
  • lea_lindemann's avatar
    lea_lindemann
    Occasional Contributor
    I'm using TestComplete version 9.10. The firefox version is 19.0. Before I used Firefox 18.2 and it did not work with that either. So I guess it's rather some setting than some version problem? Anything else I can try?
  • lea_lindemann's avatar
    lea_lindemann
    Occasional Contributor
    Okay, I will try that.



    I also got the information that the specific table that does not get the RowCount/ClolumnCount properties is peodically updated via Ajax. Might that pose a problem?
  • AlexKaras's avatar
    AlexKaras
    Icon for Champion Level 3 rankChampion Level 3
    Hi,



    Yes, Ajax might be a source of the problems as well. After some object is modified by Ajax function, this should be detected by TestComplete and invalidate the object in its cache. Then TestComplete will refresh the object (and its children) and it is possible that none of object's properties are available until refresh completes.

    You may try to use the WaitProperty() function (see help for more details) to pause script until the required property is available and continue test execution immediately after the property becomes available.
  • lea_lindemann's avatar
    lea_lindemann
    Occasional Contributor
    I installed TestComplete 9.20 and Firefox 18.0.



    Now TestComplete can spy objects within the web page and also the properties appear in the object browser. Unfortunately TestComplete does not locate the objects correctly, i.e. when I highlight a button it is shown in a different location than it is. Also the Click() methods won't work because they click on the wrong spot.



    Is there anything I can do about that?







    Right now we're supposed to always use the lastest version of Firefox for test automation. As it seems that TestComplete has some problems with the more recent Firefox versions I suppose these problems will stay with us.



    I'm thinking of switching to Internet Explorer as primary browser for the tests. Is this recommendable? I.e. is the support for Internet Explorer better/more stable?
  • lea_lindemann's avatar
    lea_lindemann
    Occasional Contributor
    Okay, that did the trick. Altough I thought I had already tried that.



    Thank you very much!



    How long does it usually take until a TestComplete Patch is released for a new Firefox version?