The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
JavaBeginnersFaq
"Yesterday is history, tomorrow is a mystery, and today is a gift; that's why they call it the present." Eleanor Roosevelt
Originally posted by Marilyn de Queiroz:
How does the application process the stuff the XHTML form returns? Does it use servlets?
Originally posted by Marilyn de Queiroz:
J2EE does come with a "reference implementation" of a servlet container, but it would probably be simpler to use a different free implementation of a servlet container like Orion or JBoss or perhaps OC4J.
This page might be useful if you decide to go this route.
On the other hand, if you just want to test the input and output of the XHTML page, something along the lines of HTTPUnit might be useful.
[ June 05, 2005: Message edited by: Marilyn de Queiroz ]
Originally posted by Ilja Preuss:
I don't yet understand what your code has to do, and what you want to test. Please elaborate.
[OCP 17 book] | [OCP 11 book] | [OCA 8 book] [OCP 8 book] [Practice tests book] [Blog] [JavaRanch FAQ] [How To Ask Questions] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
Originally posted by Jeanne Boyarsky:
The way to do this is through a mock objects framework such as easyMock or jMock. These let you create a pretend HttpServletRequest with whatever parameter values you want in as many combinations as you want.
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Originally posted by Clay Bridges:
Just wanted to post the denouement. I'm coding J2SE in Eclipse, and I needed a servlet to enable an interactive test of a java-generated XHTML form, the resultant POST/GET responses. For my purposes, the easiest way to do this turned out to be using the Jetty servlet container and the Jetty Launcher plugin for Eclipse. Dead easy, and IMO, way easier than Tomcat.
Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Did you see how Paul cut 87% off of his electric heat bill with 82 watts of micro heaters? |