> Now that Dennis is
>considering leading the charge on adopting the Shale Mock Test stuff
>maybe we could consider porting the cactus tests to use the mock
>stuff.

I'm not considering it, I'm going to do it - once I am no longer doing overtime 
for my day job.

>My preference is for mock over the container testing since its much
>simpler.

The cactus tests I saw (in MyFaces) were for HtmlSelectOneMenu .  I recall the 
rendered output was being tested.  I thought it was pretty cool, but you can do 
this outside of container.  These links will wrap, but here is a test for 
HtmlSelectOneMenu using shale mocks.

http://cvs.sourceforge.net/viewcvs.py/jsf-comp/test/src/java/org/apache/myfaces/test/AbstractUIComponentTestCase.java?rev=1.2&view=auto

http://cvs.sourceforge.net/viewcvs.py/jsf-comp/test/src/java/org/apache/myfaces/component/html/ext/AbstractHtmlSelectOneMenuTestCase.java?rev=1.2&view=auto

You can just run it in JUnit, and get a String w/ the HTML.  However if we have 
someone willing to get the Cactus tests up in Continuum, I'm sure we don't have 
to treat this as "Cactus or No-Cactus" .

Dennis Byrne



Reply via email to