cancel
Showing results for 
Search instead for 
Did you mean: 

Stopping creation of Aliases by default

SOLVED
Highlighted
Contributor

Stopping creation of Aliases by default

Is there any way of stopping TC creating of Aliases by default when new elements are mapped.

 

TC produces a lot of elements we dont need, and we'd like to maintain the Alias map by adding as required into a fairly simplified UI Alias map.

2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
Community Hero

Re: Stopping creation of Aliases by default

No.  Because Aliases are the preferred way of referencing an object, every time an object is mapped, an Alias is created.  So, if you want to modify Aliases after mapping, that's a "step 2" in your mapping process.


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available

View solution in original post

Highlighted
Community Hero

Re: Stopping creation of Aliases by default

That's the best approach, really.  In my experience, while generally you don't need alot of those DIVs mapped, occasionally I've needed it to do some other detection or verification.   

 

Modifying the Alias after the fact is relatively easy.  Highlight the objects in the Alias tree, right click, and select "Exclude Items".  This preserves the mapping for the identification engine but "telescopes" your Alias tree to something more manageable.

 

ExcludeItems.png


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available

View solution in original post

5 REPLIES 5
Highlighted
Community Hero

Re: Stopping creation of Aliases by default

No.  Because Aliases are the preferred way of referencing an object, every time an object is mapped, an Alias is created.  So, if you want to modify Aliases after mapping, that's a "step 2" in your mapping process.


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available

View solution in original post

Highlighted
Contributor

Re: Stopping creation of Aliases by default

Thanks Robert. 

 

I'd say that's a good idea for desktop apps but for java/REACT web pages with vast numbers of nested DIV containers which all gets mapped it prodces a lot of clutter we dont' need.

 

I'd like to maintain a high level alias structure like this:

Browser

>>Page

>>>>Content Container

>>>>>>Menu Container

>>>>>>>>Option 1

>>>>>>>>Option 2

>>>>Toolbar Container

>>>>Modal popups etc

 

Mapping a single button can produces 15-20 parent objects  which is fine in Name Mapping  but messes up Aliases. 

 

I'lll have a go at the approach you mentioned and let you know.

 

Thanks

Highlighted
Community Hero

Re: Stopping creation of Aliases by default

That's the best approach, really.  In my experience, while generally you don't need alot of those DIVs mapped, occasionally I've needed it to do some other detection or verification.   

 

Modifying the Alias after the fact is relatively easy.  Highlight the objects in the Alias tree, right click, and select "Exclude Items".  This preserves the mapping for the identification engine but "telescopes" your Alias tree to something more manageable.

 

ExcludeItems.png


Robert Martin
[Hall of Fame]
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
Vegas Thrill Rider
Extensions available

View solution in original post

Contributor

Re: Stopping creation of Aliases by default

I've seen that option but was to "afraid" to use it in case it broke too many tests.

 

We have a lot of legacy mapping in our our name map which needs removing as it's causing to many recogition issues and causing new mapped elements to be placed into the wrong part of the tree. 

 

I've created a copy of our project with a deleted name map and will re-create it with the lessons learnt from our previous project and use the method you mentioned above to keep it trimmed down.

 

Thanks for your help with thiis.  Much appreciated.

Highlighted
Community Hero

Re: Stopping creation of Aliases by default

Hi,

 

Just to ensure that you are aware about Tools|Options|Engines|NameMapping|Map Object Names Automatically and Update Name Mapping During Test Run options.

I prefer to have them not checked and manually map only those elements that I need and control what properties are used for their identification.

Then I organize Aliases tree in a way that is convenient to me. (Robert's note about DIVs is perfectly valid.)

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================
New Here?
Join us and watch the welcome video:
Announcements
Top Kudoed Authors