Forum Discussion

william_roe's avatar
william_roe
Super Contributor
10 years ago
Solved

Moving Mapped Objects

Development has made changes in which panels, frames, or sections have been added and/or removed in the object hierarchy. If these changes can be identified across the application is it possible to move them in Mapped Objects viewer without having to screen by screen and object by object and re-mapping every object?

 

According to this article  it sounds as though it is possible. However, it's unclear if changes would also need to be made to the Name Mapping or if these would be updated automatically. We have extended mapping turned on throughout much of the hierarchy (which we understand can slow the find) but right now the speed is not an issue. Here's a past example where a textbox was moved.

 

..formMainform.panelPartialpropertiesC1.panel.section.textboxOverrideMin
..formMainform.sectionOrderinformation.textboxOverrideMin

 

Does anyone have a recommendation about how to approach this in the most efficient manner?

  • I doubt I could reliably explain the process, but I was able to remove the element from the hierrarchy by editing the xml outside of TestComplete. The unused node was first (carefully) removed from the name mapping file. All keyword test filess were then opened and a search/replace performed which removed the eliminated level (including the trailing period). Doing it in this fashion preserved the alias mappings and no individual steps within the test had to be touched. 

     

    I hope this helps someone out there.

6 Replies

  • mgroen's avatar
    mgroen
    Frequent Contributor

    Interesting question.
    I'm interested in recommened approach as well.

     

    • william_roe's avatar
      william_roe
      Super Contributor

      It's been nothing but cricket in here. Nobody seems to have done this or willing to venture a guess as to an approach. I'm taking a stab at it today but don't sense it will work.

      • william_roe's avatar
        william_roe
        Super Contributor

        The attempt to move mapped objects did not work and has been rolled back. I was able to move objects to the up a level but it seems as though the named mapping was lost and I had to re-map the fields. When I attempted to move multiple items all but the first item seemed to disappear. To say the least, moving mapped objects was a complete failure. It's possible I was doing something wrong but short of getting somone from support on the GoToMeeting I'm stuck with re-mapping every step again. And given this type of change will likely happen again I am considering giving up on automated UI testing all together.

  • NisHera's avatar
    NisHera
    Valued Contributor

    The document you mentioned says object mapping hierarchy can be changed. (Probably assuming AUT is static). Nothing mentioned about developer changing object hierarchy.

     

    please read following thread may useful thread

     

     

    • alfhan's avatar
      alfhan
      Regular Visitor

      Hello,

      i think in such a case it's the best and easiest to record the scripts once again.

      --

      regards

      Alfred

      • william_roe's avatar
        william_roe
        Super Contributor

        I doubt I could reliably explain the process, but I was able to remove the element from the hierrarchy by editing the xml outside of TestComplete. The unused node was first (carefully) removed from the name mapping file. All keyword test filess were then opened and a search/replace performed which removed the eliminated level (including the trailing period). Doing it in this fashion preserved the alias mappings and no individual steps within the test had to be touched. 

         

        I hope this helps someone out there.