Forum Discussion

BrandonH's avatar
BrandonH
Contributor
9 years ago
Solved

Do I Need to Have Developers Add Unique Object Identifiers?

Hi,

 

    I'm testing a custom, GUI based application with many objects of very similar properties.  The only unique identifier between them is currently the index #; however, the index # will update occasionally.  I do not want to rely on specifying the location or size of the objects as these can change.  All objects have a Name property of: Window("SWT_Window0","",#) where # is the Index #.

 

     Do I need to ask the developers to add a unique identifier so that my tests can be robust or is there another way (i.e. is there a way to map via image identification?)?  What identifier would you advise be added to the objects?

 

 

 

 

Thanks,

  • Hey avkour13

    Id double check your requirements or speak to dev about the correct authentication scheme you need to use. Considering the error response indicates auth failure this is most likely a problem even if you are sending a userid as a URI/Template parameter cos i'd be surprised if anything relating to authentication was passed in a URI as the details could be sniffed (so totally not secure)

    Nice one,

    Rich

5 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    Something doesn't seem right to me... you have an application that has SWT objects... that's what SWT_Window is... but it's not using the SWTObject method for identifying those objects.  This seems to indicate that the Java Application Support plug in is not installed.  

     

    Please check File | Install Extensions... expand the "Desktop" item and make sure that extension is checked.

    • BrandonH's avatar
      BrandonH
      Contributor

      Robert,

       

          Thanks, looks like you are correct, Java Application Support plug-in is not installed.  Is that only available using the Desktop Module license? Apparently I only have the Web Module license.

      • tristaanogre's avatar
        tristaanogre
        Esteemed Contributor

        My suspicion is that, yes, if you don't have the Desktop license, you won't have that plugin.  Not being a SmartBear employee myself, I hesitate to tell you what you need to do.  I'd suggest you contact your sales rep and see what they can do for you.

  • AlexKaras's avatar
    AlexKaras
    Icon for Champion Level 1 rankChampion Level 1

    Hi,

     

    While everything told by Robert about SWT is correct and should be clarified, the generic answer to your question is:

    "Yes! Having all UI objects used in automated tests assigned their unique and stable IDs during development is the best and recommended practice for any application type (desktop, web, mobile, etc.)".

    • tristaanogre's avatar
      tristaanogre
      Esteemed Contributor

      My apologies for not answering your question directly, BrandonH.  AlexKaras is correct... maintaining a partnership with the developers in building automated tests is always a good idea and anything they can do and are willing to do to make your job easier is always a good idea.

       

      If they can't give you the unique identifiers, if you get the plug-in stuff sorted out, you should find more accurate identification available.