Forum Discussion

Tris's avatar
Tris
Contributor
4 years ago

How to find where mapped objects are used

Hi all,

 

Just wondering if there was a way to find out which objects in the name mapping have been used in KeyWord tests? 

 

For example, if I want to amend a mapped object or alias object is there a way to see which tests are using it already before I make the changes to ensure I don't break other tests when I make the changes?

 

Thanks

  • Tris's avatar
    Tris
    4 years ago

    Seems the only way to find some reference of objects is to use the find functionality (ctrl + f) and search the alias/mapped object string. It appears that it will find it if mentioned in the value column of a keyword test or as a string in a script, however it won't pick up an object being used in an action.

     

     

6 Replies

    • Tris's avatar
      Tris
      Contributor

      Hi Alex,

       

      Not quite what I was looking for, this only gives you an idea of what is being used in the NameMapping, what I was looking for is if there was a way to identify exactly which tests an object is being referred to, so rather than a high level "this object is being used" I would be looking for "this object is being used in test X, Y and Z" specifically.

       

      To my knowledge I don't think there is such a feature (but others like Katalon have this) so was wondering if I had missed something.

       

      Thanks,

      Tris

      • tphillips's avatar
        tphillips
        Frequent Contributor

        It's a bit tricky because for example we use the javascript eval() function to programmatically access name mapping, and we often assign name mapping to variables to shorten the lines where we use them. I wouldn't expect TestComplete to know about these instances because they're a little bit obfuscated from it.

         

        For the most part I just use searching (grep, or VSCode's searching) to find where name mapping is used.