What Z is saying here is that you need to address the problem of the
brittle UI with the developers.  If you explain the testability issue
to them, its often possible to work out an agreement that they will do
something like leave the ID values the same (all the while that they
move stuff around, change classes, etc etc)..

That way they can pretty much re-design to their hearts content, as
long as they leave the ID for the elements the same.  They can change
the name, or the class or the location on the screen or nearly
anything they like, as long as they leave the ID unchanged.  Then as
long as the element is still on the page, still active, and performs
the same basic function as before, your tests should continue to work.

ID's (at least I find) seem to be ideal for this since they are
supposed to be unique within a page, and as a result Watir is pretty
robust about returning an element (even sometimes if the element type
has changed) to you as long as the specified ID is found.


On Aug 3, 4:29 am, Željko Filipin <zeljko.fili...@wa-research.ch>
wrote:
> On Tue, Aug 3, 2010 at 1:27 PM, Sharma Vishav <sharma.vis...@gmail.com>
> wrote:
>
> > yes you did answer my question
>
> I forgot to say before, it is possible to automate tests even when
> developers do not care about testability (and/or having automated tests),
> but automation will be a lot easier if developers cared about it.
>
> Željko

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

You received this message because you are subscribed to 
http://groups.google.com/group/watir-general
To post: watir-general@googlegroups.com
To unsubscribe: watir-general+unsubscr...@googlegroups.com

Reply via email to