For each page-element: Generate smarter, more meaningful name than textbox1 - Mendix Forum

For each page-element: Generate smarter, more meaningful name than textbox1

6

Currently the property 'name' gets generated as <elementtype><number>. Which is fine, it works. But it is more meaningful if the element's label is also added. So <elementtype>_<label>_<number>.

This will make your have Selenium-recordings more readable and easier to interpret. Also the browser's console will be even more easy to read.

asked
4 answers

I’ve put this on our backlog. We are working on version control improvements now. Though this is not strictly a *conflict*, I can understand that those errors are quite annoying.

Created

I especially agree with you on the (merge) conflicts problem. When two developers add the same type of item somewhere, these items will have always have the same id if not changed and will cause a conflict when synchronizing with SVN. This is also the case without using branches.

Created

Btw. It will also prevent merge conflicts! Merge conflicts will arise when working in branch A you add a button, and someone else working in branch B also adds a button on the same page. Merging B in A will result in merge conflicts like these:

Created

Hi,

I created a Selenium plugin that makes the recorder use the class mx-name-widgetname as selector. So you can choose the name in the modeler and Selenium will use that. 

 

You can find the plugin here:

https://github.com/mgroeneweg/SeleniumMendixLocatorBuilder

 

Hope this helps.

Created