PDA

View Full Version : In-container testing a Spring MVC web app ?



puccio
Jul 10th, 2006, 02:05 PM
Hi,

I would like to do some in-container testing on my Spring MVC app (which has a rich client interface which makes XmlHttpRequests and some DOM manipulation on the JSP pages).

I was thinking about using JUnit as testing framework infrastructure, HtmlUnit libraries to emulate browser-like black box beahviour (which good support for Javascript and XmlHttpRequests), Jetty as embedded servlet container to be instantiated during test set up, and Hsqldb as in-memory db where I would save and delete datas to execute my test methods in isolations.

Can someone give me some advices for the given scenario (maybe pointing to some resources), or even a suggestion for some better way to make in-container testing?

manifoldronin
Jul 12th, 2006, 11:02 AM
I have been exploring in-container testing with script languages like beanshell or groovy - especially groovy which provides out-of-box junit integration. The rapid nature of script languages is perfect for testing code, and the best part is you don't have to bounce the application or the server after changing some test code.

manifoldronin
Jul 12th, 2006, 11:03 AM
Oh, and of course Spring 2.0's script language support makes it even better for Spring MVC applications.