I am sure Marc will step in if I get this slightly wrong
but my understanding is that:
onkeyup has 'hooks' in place within htmlunit but no implementation
(and nothing within webtest)
onblur has 'hooks' and an implementation within htmlunit but nothing
at all in webtest
A question I have with many of these events and how they would look
within WebTest is what granularity do people want to support.
The easiest hook would be to cause setInputField to trigger some events
but that doesn't match exactly what a browser would do. In a browser
you would get events for each keystroke as you typed it. Whereas
in the simplest form we would be just having one lot of events
for all the keystrokes.
We could of course add a <sendKeyStroke> or <addKeyStrokeToField>
step but we would need to make it clear that these weren't used
for testing normal form functionality but just browser js functionality.
Cheers, Paul.
bat wrote:
> hi marc,
>
> i'm afraid i don't have the skills to fix the problem ;-)
>
> but i've taken a cursory glance at the
>
http://htmlunit.sourceforge.net/javascript-howto.html htmlunit site and i
> was quite surprised to read this:
> "Some event handlers are already implemented and will be triggered at the
> appropriate time (see table below).
> ...
> onblur: The method WebClient.moveFocusToElement(...) will change the focus
> to the appropriate element. This event will be triggered when an element
> loses focus."
>
> it must be a misunderstanding on my part, but that statement leaves me
> rather confused.
>
> greetings
>
> christian
>
>
>
>> So you may find a workaround this way but the safer way would surely be
>> to submit a patch allowing htmlunit/webtest to handle these events
>> natively ;-)
>>
_______________________________________________
WebTest mailing list
WebTest@...
http://lists.canoo.com/mailman/listinfo/webtest