Have you tried using a form tester? On Dec 2, 2011 10:58 AM, "Fabiosakiyam" <fabiosakiy...@gmail.com> wrote:
> Hi guys, > > Im trying to test a component i've made using wicket tester, but im having > a > problem to assert a modelValue. > Im trying to input data on my component fields, and then submit. The > problem > is, when i try to assertModelValue, it says it's empty. > > My component is declared like this, in a blankpage.java : > > ComponentX x = new ComponentX(wicketid, propertyModel) > > and my test start like this: > > wicketTester.startPage(blankpage) > wicketTester.setParametersForNextRequest(path, value); > wicketTester.submitForm(formId) > wicketTester.assertModelValue(componentpath, expectedvalue) > > i don't know what am i missing... i tested the component manually, and it's > working. > so either i don't know how setParametersForNextRequest() works...or i'm > missing something else.. > Any ideas? > > Thanks > > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/WicketTester-setParameterForNextRequest-doubt-tp4147729p4147729.html > Sent from the Users forum mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > >