Just modified CactusStrutsTestCase from the suggestions, problem still.
Martin Gainty <[EMAIL PROTECTED]> wrote:This is a kluge but did you consider trapping it the parameter from ServletTestCase String doParam = config.getInitParameter("url-pattern"); then later setting the correct url-pattern doParam = "*.do" config.setInitParameter(doParam); Martin- ----- Original Message ----- From: "Yahzz Yan" To: Sent: Tuesday, May 24, 2005 12:38 PM Subject: Cactus not working well with Struts when url-pattern not use *.do > We are trying to use Cactus Struts testing framework to test our struts > application. When we run our suite of tests, we notice that that Cactus > corrupts the Struts configuration at runtime which causes the struts form > actions to point to an invalid url - which has .do in it whereas our > application does not use .do. > > To be precise, here is the exact scenario: > 1) We have our ActionServlet mapped to /action/*.go and not to *.do > 2) We run our suite of tests (cactus tests) and the tests run fine. > 3) then we go back to our application and the struts form actions are all > broken - they have *.do at the end which is not configured for our > application. > 4) If we restart the app and not invoke the test suite and test our > application, all the forms work well. > > If we change our servlet mapping to *.do, then everything works fine. > > It seems like Cactus assumes that the mapping is always *.do. > Has anyone faced a similar problem? do you know how to fix it - other than > changing the mapping to *.do. Please advise and thanks. > > > > __________________________________________________ > Do You Yahoo!? > Tired of spam? Yahoo! Mail has the best spam protection around > http://mail.yahoo.com --------------------------------- Yahoo! Mail Mobile Take Yahoo! Mail with you! Check email on your mobile phone.