Forum Discussion

Hieronimus's avatar
Hieronimus
New Contributor
3 years ago

Object recognition in web applications

Hello,

 

It seems that there is a recent change in object recognition in web application with Chrome. When i use Object spy to reconize a control it now displays in fullname property a FindElement method, eg Sys.Browser("chrome").Page("https://mywebapplication.bzh").FindElement("//label[.=""Date d'intervention""]").

Previously it was a full path, eg Sys.Browser("chrome").Page("https://mywebapplication.bzh").Form("mainForm").Panel(0).Panel("page_content").Panel(1).Panel(1).Panel(0).Panel("s_crits").Panel(0).Panel("paramsDynamiques").Panel(0).Panel(0).Panel(0).Panel("crit_rapide_198291").Panel("crit_rapide_198291_s_selection").Panel(1).Panel(0).Panel(0).Panel(0).Label(0).

My problem is that I can no more handle objects near a specific objects using '.parent' of '.child(0)', '.textnode(0)' in my scripts.

Is the ".findElement" the new way testComplete reconize web objects on Chrome, is it just an option of the project? 

  • Ok I can auto reply to my question 😁, it was due to the parameter "Use XPath and CSS selectors for web objects (required for cross-plateform web tests).

    I disabled the parameter and I got the previous behaviour for my automated tests.

3 Replies

  • Marsha_R's avatar
    Marsha_R
    Champion Level 3

    When did you last update TestComplete and what version are you on now?

  • Hieronimus's avatar
    Hieronimus
    New Contributor

    Ok I can auto reply to my question 😁, it was due to the parameter "Use XPath and CSS selectors for web objects (required for cross-plateform web tests).

    I disabled the parameter and I got the previous behaviour for my automated tests.