Forum Discussion

christophert's avatar
christophert
Occasional Contributor
10 years ago

Does TestComplete work with QTreeView controls?

I am not new to TestComplete but have never tested C++ Qt applications using it, only C++/MFC projects. I have an application developed using Qt 5.4.2 which I need to test. Two of the major user interface components are implemented as QTreeView controls.

 

I see documentation about QTreeWidget support but nothing about QtreeView support except for http://support.smartbear.com/viewarticle/26146/  

 

That links to an article using Qt 4.7 and relies upon the control having a "CurrentIndex" property. I cant see that property when I inspect my objects. I have inserted "QTreeView" into the Object Mapping of my project under QTreeWidget but this doesn't help.

 

Am I wasting my time trying to interrogate these controls in TestComplete?

 

Cheers,

   Chris

  • TanyaYatskovska's avatar
    TanyaYatskovska
    SmartBear Alumni (Retired)

    Hi Chris,

     

    To test, Qt 5.4.2 applications, you should use TestComplete 11.11. Do you use this product version?

    As for your control, at the moment, its testing is possible only via accessing the control’s native properties and methods. The sample you’ve found demonstrates this approach. If you don’t see the CurrentIndex property, please check if you use the Advanced View mode in the Object Browser and displaying hidden properties are allowed in TestComplete.

    • christophert's avatar
      christophert
      Occasional Contributor

      Hi Tanya,

        Thanks for your reply. I was using v10 of TestComplete. I have found the link to the installation image of v11.20.1491 on my account page so I will do further investigation with that.

       

      Cheers,

       Chris.

       

      • christophert's avatar
        christophert
        Occasional Contributor

        After further investigation with v 11.2 I found it extremely cumbersome to work with the QTreeView control. Recording tests did not work very well. Instead of selecting items by name e.g. "rootname|nodename|leafname", only clicks at co-ordinate points were saved when interacting with the control.

         

        I have ended up using Squish for Qt to test the application as we already have licences in my company for that product. I find it inferior to TestComplete with repect to test management but it works out-of-the-box with QTreeView and items can be referred to by name.

         

        Cheers,

            Chris