You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Juergen Donnerstag (JIRA)" <ji...@apache.org> on 2009/12/22 17:44:29 UTC

[jira] Resolved: (WICKET-2616) BaseWicketTester chooses a disabled component as the source of an AjaxFormSubmit event

     [ https://issues.apache.org/jira/browse/WICKET-2616?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Juergen Donnerstag resolved WICKET-2616.
----------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.5-M1
                   1.4.6
         Assignee: Juergen Donnerstag

> BaseWicketTester chooses a disabled component as the source of an AjaxFormSubmit event
> --------------------------------------------------------------------------------------
>
>                 Key: WICKET-2616
>                 URL: https://issues.apache.org/jira/browse/WICKET-2616
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.4.4
>         Environment: Linux, Sun JDK 1.6
>            Reporter: Jari Aarniala
>            Assignee: Juergen Donnerstag
>             Fix For: 1.4.6, 1.5-M1
>
>         Attachments: WICKET-2616.patch
>
>
> As of 1.4.4, disabled components can no longer submit forms (and rightly so):
> http://fisheye6.atlassian.com/browse/wicket/trunk/wicket/src/main/java/org/apache/wicket/markup/html/form/Form.java?r1=835242&r2=829503
> BaseWicketTester, however, doesn't check whether a submitting component is enabled when it chooses a component as the source of a submit event, it only checks the visibility:
> http://fisheye6.atlassian.com/browse/wicket/trunk/wicket/src/main/java/org/apache/wicket/util/tester/BaseWicketTester.java?r=835641#l1287
> We have a TextField with an AjaxFormSubmitBehavior, and in the same form there's a disabled AjaxButton. In our test, we trigger a submit event from the TextField, but BaseWicketTester sets the disabled AjaxButton as the source, causing the check in Form.java to fail and throw an Exception.
> In the browser everything works fine, since the AjaxButton's *inputName=value* is not added to the request parameters, as expected.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.