Hi list
with the following test
public void testFormAndLinkAreSubmitted()
    {
        WicketTester tester = new WicketTester();
        tester.startPage(FormPage.class);

        FormPage page = (FormPage)tester.getLastRenderedPage();

        Assert.assertFalse(page.isSubmitLinkSubmitted());
        Assert.assertFalse(page.isFormSubmitted());

        FormTester formTester = tester.newFormTester("form");
                formTester.setValue("field", "2");//added
        formTester.submitLink("link", true);

        page = (FormPage)tester.getLastRenderedPage();

        Assert.assertTrue(page.isFormSubmitted());
        Assert.assertTrue(page.isSubmitLinkSubmitted());
                tester.assertModelValue("form:field", 2);//added
    }

extracted from FormPageTest present in the wicket code base i get a test
file on the line  tester.assertModelValue("form:field", 2); (the model has
value 1 (the default) instead of 2), this acts like the FormTester miss to
process something. The same test executed with wikcet 1.5-M1 (the trunk)
terminate successfully, while with official release 1.4.10 fails.
I can't imagine why  with 1.4 fail.
Is it a plan to back port on the 1.4 branch the changes that fixed this test
on the trunk?
 Best regards, thanks in advance
  Andrea

Reply via email to