thanks for the quick answer... regards Nino
Johan Compagner wrote:
This is already fixed but it didn't make it into the RC as it seems It is because you use a BufferedWebResponse with your mock application if you make it a WebResponse then it works fine for now. /** * [EMAIL PROTECTED] org.apache.wicket.protocol.http.WebApplication#newWebResponse( javax.servlet.http.HttpServletResponse) */ *protected* WebResponse newWebResponse(*final* HttpServletResponse servletResponse) { *return* *new* WebResponse(servletResponse); } johan On Nov 12, 2007 12:05 PM, Nino Saturnino Martinez Vazquez Wael < [EMAIL PROTECTED]> wrote:Hi After updating our maven dependencies to 1.3 rc1 we are now getting null pointer exceptions in almost all our tests.. Is this something that are expected? A quick look at the migration guide did not give anything. Any ideas? We do not get these errors in beta 4, but we do get the redirect error(but this does not break the test). Heres a partial stacktrace: Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.066 sec <<< FAILURE! testCanRender(dk.polfoto.admin.base.texts.ManageSlogansPageTest) Time elapsed: 0.059 sec <<< ERROR! java.lang.NullPointerException at org.apache.wicket.protocol.http.MockHttpServletResponse.sendRedirect( MockHttpServletResponse.java:534) at org.apache.wicket.protocol.http.WebResponse.redirect(WebResponse.java:232) at org.apache.wicket.protocol.http.BufferedWebResponse.close( BufferedWebResponse.java:66) at org.apache.wicket.protocol.http.MockWebApplication.processRequestCycle( MockWebApplication.java:386) at org.apache.wicket.util.tester.FormTester.submit(FormTester.java:588) at dk.polfoto.admin.testutil.WebTestCase.attemptLogin(WebTestCase.java:67) at dk.polfoto.admin.testutil.WebTestCase.assertLogin(WebTestCase.java:84) at dk.polfoto.admin.base.texts.ManageSlogansPageTest.setUp( ManageSlogansPageTest.java:14) at junit.framework.TestCase.runBare(TestCase.java:125) -- Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Nino Martinez Wael Java Specialist @ Jayway DK http://www.jayway.dk +45 2936 7684 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
