Re: Re: Re: {Disarmed} Antwort: [TEST] Apache Struts 7.0.0-M10 test build is ready
Lukasz Lenart <[email protected]>
| Newsgroups | gmane.comp.jakarta.struts.devel |
|---|---|
| Message-ID | <CAMopvkMS05HoCea9k7B=1W6Q6NnbTONM=doYfEZiLio40C8DVQ@mail.gmail.com> |
wt., 12 lis 2024 o 08:28 <[email protected]> napisał(a): > > Hallo Lukasz, > > for sure - the Test and Action is quite simple > > > > public class DispatcherTest extends StrutsJUnit4TestCase<Object> { > > @Test > > public void testParameters() throws UnsupportedEncodingException, ServletException { > > request.addParameter("test", "me"); > > executeAction("/test/dispatcher/execute.html"); > > assertEquals("me", findValueAfterExecute("#parameters.test[0]")); > > assertEquals("bar", findValueAfterExecute("#parameters.foo")); > > } Thanks a lot, used that in the final unit test, gives more information about what's expected. Cheers Łukasz