Hi Marc and all,
Good point.
Let's add two parameters, and allow them to be set by defautl in config
element, but also to be overridden if required in verifyText call. That way
default behaviour stays the same, but people not concerned with html markup
and who want to see current state of page always, just set
verifyTextDynamic=true and verifyTextIgnoreMarkup=true in config.
If they then specifically want to test markup in a given instance they add
verifyTextIgnoreMarkup=false in the relevant calls to verifyText.
And for other people it behaves as it always has.
To keep it simple I would suggest that in verifyTextIgnoreMarkup=true mode
it ignores all markup and attributes EXCEPT that I think any markup
separating text should be converted to a single space (i.e. not multiple
spaces) and that any should be converted to spaces. Effectively this
means people who don't want to don't have to come to grips with html, xpath
or regex.
I hope the above input from a non-technical webtest user is not too stupid!
regards,
John
On 11/6/07, Marc Guillemot <[EMAIL PROTECTED]> wrote:
>
> Hi John & Paul,
>
> verifyText in the current version is misleading. I think that we should
> deprecate it and rename it to something like verifyResponseText.
>
> Nevertheless we need a step to verify text in the current state of the
> page. verifyText is probably the best name, but it makes the deprecation
> complicated.
>
> We need to precisely define how this "new verifyText" should work. For
> instance I guess that <*new verifyText* text="Hello John"/> should pass
> for
> Hello <em>John</em>
> but what is with
> Hello <div>John</div>
> or
> <table>
> <tr>
> <td>Hello</td>
> </tr>
> <tr>
> <td>John</td>
> </tr>
> </table>
>
>
> Cheers,
> Marc.
> --
> Blog: http://mguillem.wordpress.com
>
>
> John and Pip wrote:
> > Hi Marc and Paul,
> >
> > While I can see it is not backward compatible as would change behaviour
> > of existing scripts, the reality I would have thought is that you would
> > ideally always want to see current page state. That is how the
> > "mainstream" tools work and is one of the initially obvious limitations
> > when people evaluate or learn Canoo WebTest.
> >
> > So I would suggest (beg!?) that it become the default behavior to look
> > at current page state, and if necessary an option be provided in the
> > config element to override it in one place back to the previous
> behaviour.
> >
> > After all - we do want WebTest to become an end user tool as well as a
> > java guru's tool right? (rhetorical question I think - I'm trying to
> > teach my teenage daugher and her boyfriend but unfortunately for reasons
> > like this have had to start them on Selenium).
> >
> > regards,
> > John
> >
> > On 10/24/07, *Paul King* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Marc Guillemot wrote:
> > > - add an attribute to specify last response or current page state
> >
> > Maybe:
> >
> > <verifyText ... useDom="true">
> >
> > with some documentation and default to current behaviour, i.e.
> false?
> >
> >
> > Paul.
> > _______________________________________________
> > WebTest mailing list
> > [email protected] <mailto:[email protected]>
> > http://lists.canoo.com/mailman/listinfo/webtest
> >
> >
>
> _______________________________________________
> WebTest mailing list
> [email protected]
> http://lists.canoo.com/mailman/listinfo/webtest
>