Works great, thanks!
Timo Rantalaiho wrote: > > On Thu, 22 Feb 2007, Gohan wrote: >> I'm trying to test one of my wicket pages using WicketTester. I'd like to >> know how I trigger a submit button I have inside a form. I've managed to >> click on a Link by using >> wicketTester.getServletRequest().setRequestToComponent(link); >> wicketTester.processRequestCycle(); >> but this does not work on the submit button. > > FormTester tester = wicketTester.newFormTester("wicket:path:to:form"); > tester.submit("wicketIdOfButton"); > > - Timo > > -- > Timo Rantalaiho > Reaktor Innovations Oy <URL: http://www.ri.fi/ > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > Wicket-user mailing list > Wicket-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wicket-user > > -- View this message in context: http://www.nabble.com/Click-button-in-unit-test-tf3273168.html#a9101529 Sent from the Wicket - User mailing list archive at Nabble.com. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user