[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cactus-user
Subject:    Re: End handler happened before every page I am checking does not
From:       Kazuhito SUGURI <suguri.kazuhito () lab ! ntt ! co ! jp>
Date:       2005-07-29 10:37:21
Message-ID: 20050729.193721.78705563.suguri.kazuhito () lab ! ntt ! co ! jp
[Download RAW message or body]

Hi Meir,

In article <84D243F8DA11FF4BBEB99D30DFBAF6BF04C1A8D0@arava.openu.local>,
Thu, 28 Jul 2005 14:21:31 +0200,
Meir Kalter <meirka@openu.ac.il> wrote: 
meirka> I will start with part of my code:
meirka> 
meirka> 	public void beginMainData(WebRequest theRequest)
meirka> 	{
meirka>         //		 Set up HTTP related parameters
meirka> 	    theRequest.setURL("myserver", "/app", "/index2.html",
meirka> 	        null, null);
meirka> 	}
meirka> 
meirka> 	public void endMainData(com.meterware.httpunit.WebResponse
meirka> theResponse)
meirka> 	{
meirka> 		      WebTable table = null;
meirka> 		      String title = null;
meirka> 			try {
meirka> 				assertNull(null);
meirka> 				title = theResponse.getTitle();
meirka> 				assertEquals("test",title);
meirka> {}
meirka> What need to be happen is that the index2.html will be received , then the
meirka> function endMainData will be happened.

Could you show us testMainData method?
The testMainData() method should call appropriate methods
to write the page content to the output-stream of the response object.

Use of WebRequest#setURL method does not mean that
we can get the specified resource as a WebResponse instance.
The method is provided to control value returned by some methods of
javax.servlet.http.HttpServletRequest, getPathInfo() for example,
so that we can easily test behavior of server-side methods
depending on value of requested URL.

Regards,
----
Kazuhito SUGURI

---------------------------------------------------------------------
To unsubscribe, e-mail: cactus-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: cactus-user-help@jakarta.apache.org

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic