I (almost violently) oppose any code in a a WOComponent not directly and exclusively tied to making the UI function. I try to restrict them to binding variables, cover methods, and overrides for inherited methods. Everything else belongs someplace else, either in the EO or in a layer between the EO and UI. Doing this, the UI classes become very simple. So simple, in fact, that they could not possibly break. Therefore there is no need to write tests. Any potential bugs are best caught in functionality testing.

Chuck

On Nov 7, 2005, at 7:52 AM, Sam Barnum wrote:

Slightly different topic, but how do you write tests at the component level? My WOComponent classes need a WOContext in the constructor. And there needs to be a running applicaiton, or else you run into NullPointerExceptions.

I can fake a WOContext by manually creating a WORequest with the HTTP/1.1 and URL parameters, but am running into problems creating a dummy application. Does anyone have a quick guideline for doing this?

-Sam

On Nov 3, 2005, at 11:59 AM, Christian Pekeler wrote:


I'm studying how to add unit tests to an WebObjects application. I would like to use xCode (i hate eclipse).



I highly recommend you take another look at Eclipse (or IntelliJ if you can afford it). Xcode might be a good IDE for C based projects, but for Java projects you can dramatically increase your productivity by using a specialized IDE.




  Two questions:

- Does WOUnitTest (http://wounittest.sourceforge.net/) still works?



Sure.




I see it's not updated since 3/2004...



What new features would you like to see?


Christian

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/samlist% 40prometheus-systems.com

This email sent to [EMAIL PROTECTED]



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/chill% 40global-village.net

This email sent to [EMAIL PROTECTED]


--
Coming in 2006 - an introduction to web applications using WebObjects and Xcode http://www.global-village.net/wointro

Practical WebObjects - for developers who want to increase their overall knowledge of WebObjects or who are trying to solve specific problems. http://www.global-village.net/products/practical_webobjects




_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to