[
https://issues.apache.org/jira/browse/WICKET-3471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12998764#comment-12998764
]
Martin Grigorov commented on WICKET-3471:
-----------------------------------------
I really don't see a way to move checkUsability() inside the request cycle.
There is no information about the component/behavior at that point (it gets
resolved at later point when it is too late to make the check and actually is
inside Wicket core core, not WicketTester).
As I said earlier I see two solutions:
1) make it 'protected' so you can override it to do what you need if needed
2) remove it completely
I prefer 1).
checkUsability() may not be perfect and doesn't cover all cases but seems to be
good enough for most of them.
Other opinions ?
> WicketTester checkUsability is called before the request has started
> --------------------------------------------------------------------
>
> Key: WICKET-3471
> URL: https://issues.apache.org/jira/browse/WICKET-3471
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.15
> Reporter: Emond Papegaaij
> Attachments: quickstart.tar.bz2
>
>
> For example, when clicking a link, the checkUsability method is called with
> the link before RequestCycle.onBeginRequest has been called. This causes
> tests to fail when, for example, the link has a security check that requires
> the request cycle. I've created a quickstart that demonstrates the problem.
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira