[Webtest] Extending Canoo

Jeff Nielsen webtest@lists.canoo.com
Fri, 12 Sep 2003 10:31:33 -0400


Adeel,

You can get the Javascript functionality by just turning on JavaScript in
the HttpUnit you are hooking up WebTest to.  This supports onClick, onBlur,
etc.  What you will see if you look through the WebTest code, though, is
that not all of the existing steps do things in the way that the HttpUnit
Javascript support needs.

For example, I needed to write my own version of the SetInputField step, in
order to call setParameter on the WebForm when I set a value in an input
field.  At least with the version of WebTest I am using (build 276), this is
not done in the regular code.  I would be happy to email you the steps I
wrote if that would help.

Jeff Nielsen
Digital Focus
www.digitalfocus.com

----- Original Message -----
From: "Adeel Khan" <akhan@comframe.com>
To: <webtest@lists.canoo.com>
Sent: Thursday, September 11, 2003 1:41 PM
Subject: [Webtest] Extending Canoo


> Hello All,
> We are using Canoo WebTest for testing an application for one of our
client. Despite the
> ease of use and fast test generation, the incomplete support of javascript
is causing
> problems with the testing efforts. So I am looking into extending Canoo
functionality by
> writing some of my own classes extending the existing functionality
provided by canoo.
> Specifically I am looking into these issues for right now.
> - Provide onClick support for the clicklink task.
> - Provide onBlur support for the setinputfield task.
> - Identify ways to extend support of existing Canoo code, by writing my
own custom steps
> like myclicklink and not changing the code in the Canoo classes as that
would present a
> very big maintainance problem.
> If someone has already done this could you please send me some sample code
or some ideas
> on how to make custom steps. I know there has been talk about it in the
posts but I am yet
> to see a complete example of how to extend Canoo to write your own custom
steps.
> I would really appreciate any help on this issue. Thanks much for your
time and help in
> advance.
> Adeel Khan
> _______________________________________________
> WebTest mailing list
> WebTest@lists.canoo.com
> http://lists.canoo.com/mailman/listinfo/webtest