> I agree with what you are saying, it should be kept pure.  However, from
> a practical aspect I am looking to test my actions, the stuff they call,
> and the many descriptors (validators, xwork.xml, etc) that I have setup.

We are considering the following approach to testing.

Like you, testing the action feels like we are testing only half of the
application. We anticipate using one of the many Http client classes to
simulate a browser. (see
http://jakarta.apache.org/commons/httpclient/testwebapp.html or
http://httpunit.sourceforge.net/)

Using this client, we will provide an alternate webwork.xml file that points
to special versions of our views. These alternate views are responsible for
exercising the actions in much the same way as a real client. The view will
only return content if one of these tests fail. Therefore, if the HttpClient
detects a content length, then it knows the test has failed.

The content returned from a failed test will be HTML information describing
the test

jim



-------------------------------------------------------
This SF.Net email is sponsored by: INetU
Attention Web Developers & Consultants: Become An INetU Hosting Partner.
Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission!
INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php
_______________________________________________
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork

Reply via email to