On Tue, 18 Dec 2007, Dan Kaplan wrote:
>         IModel model = new Model() {
>             public void setObject(Object obj) {
>                 name = obj.toString();
>             }
>         };

This is suspicious, I think that you should also override
getObject() to return name. Otherwise the model works a bit
strangely (always returns null).

>     public void testResubmit() {
>       //note: tester initialized in parent
>         tester.startPage(new Test());
>         FormTester ft1 = tester.newFormTester("form");
>         ft1.setValue("name", "");
>         ft1.submit();
>         tester.assertRenderedPage(Test.class);
> 
>         FormTester ft2 = tester.newFormTester("form");
>         ft2.setValue("name", "testcity");
>         ft2.submit();
>         tester.assertNoErrorMessage();        //it fails here
>         tester.assertRenderedPage(Test.class);
>     }

Could it be that WicketTester does not clear the error
message at any point? You could try clearing it explicitly
in  between the submits and / or find out if it is a
WicketTester bug.

Best wishes,
Timo

-- 
Timo Rantalaiho           
Reaktor Innovations Oy    <URL: http://www.ri.fi/ >

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to