cancel
Showing results for 
Search instead for 
Did you mean: 

Inconsistent Mapping

SOLVED
LAB
Contributor

Inconsistent Mapping

I'm trying to map the various tabs within a website, and even though the objects are named consistently, for some reason name mapping isn't.

 

Mapping the first button, test complete recognizes that the button is within the main form "portal", it created a mapped object called "portal", then the first button is mapped as a direct child of "portal". The format for that button mapping (create customer) is name.mapping.sys.browser.portal.formcreatecustomer. When I look at the fullname for that button, format is basically "url".panel.panel.panel.panel.panel.form("createcustomer"). I like that the mapping is not using the fullname, it's clean and hierarchical for this first button.

 

Next button, within same form "portal", instead of mapping it like the first button i.e. name.mapping.sys.browser.portal.formcreateuser, it maps it according to the fullname, so all of a sudden my name mapping contains "url".panel.panel.panel.panel.panel.form("createuser"). 

 

it ends up looking like this.

panel

        panel

                panel

                        panel

                                  "link"

etc etc 

not only is this confusing, but it's terrible organizationally, and .panel is used everywhere so I get overlaps in mapping (meaning multiple objects using the same mapping) I'm mapping manually and taking my time with this, but I'm not sure why there's any variance here when the objects properties are consistent. 

 

 

thanks in advance!

1 ACCEPTED SOLUTION

Accepted Solutions
Community Hero

Re: Inconsistent Mapping

Go to Tools | Options | Engines | NameMapping.  There's an option there called "Use extended find when possible".  Turn that off.

 

Extended Find is a VERY useful feature in NameMapping (see https://support.smartbear.com/testcomplete/docs/testing-with/object-identification/name-mapping/mana... for details).  However, when it's turned on by default, it can create confusion because TestComplete tries to "collapse" panels dependant upon what it "knows" at the time and what you are using.  So, mapping one object, it may use extended find with one set of panels... mapping another object, it may decide that some of the panels are not necessary and use extended find differently.  This creates the confusing hierarchy you described.

 

So... my recommendation is to turn the option off so that TestComplete does not automatically assign Extended Find... but please, certainly use it where it makes sense for you to use it.  Manually turn it on (or off) as you map components to "collapse" the hierarchy tree.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available

View solution in original post

3 REPLIES 3
Community Hero

Re: Inconsistent Mapping

Go to Tools | Options | Engines | NameMapping.  There's an option there called "Use extended find when possible".  Turn that off.

 

Extended Find is a VERY useful feature in NameMapping (see https://support.smartbear.com/testcomplete/docs/testing-with/object-identification/name-mapping/mana... for details).  However, when it's turned on by default, it can create confusion because TestComplete tries to "collapse" panels dependant upon what it "knows" at the time and what you are using.  So, mapping one object, it may use extended find with one set of panels... mapping another object, it may decide that some of the panels are not necessary and use extended find differently.  This creates the confusing hierarchy you described.

 

So... my recommendation is to turn the option off so that TestComplete does not automatically assign Extended Find... but please, certainly use it where it makes sense for you to use it.  Manually turn it on (or off) as you map components to "collapse" the hierarchy tree.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available

View solution in original post

LAB
Contributor

Re: Inconsistent Mapping

I managed to eventually get mapping consistent...but knowing _why_ it was happening is very helpful. Thanks for your time/response.

Community Hero

Re: Inconsistent Mapping

Class A? Shaded Paths?  something is not jiving here.  Are you talking about the same problem as this year old OP?


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available