You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Igor Vaynberg (JIRA)" <ji...@apache.org> on 2010/08/28 08:16:53 UTC
[jira] Resolved: (WICKET-1739) Request.getPath() doesn't honor its
contract for MockHttpServletRequest
[ https://issues.apache.org/jira/browse/WICKET-1739?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Igor Vaynberg resolved WICKET-1739.
-----------------------------------
Assignee: Martin Grigorov
Resolution: Cannot Reproduce
seems MockHttpServletRequest.getRequestURI() in latest also checks for query string and trims it
> Request.getPath() doesn't honor its contract for MockHttpServletRequest
> -----------------------------------------------------------------------
>
> Key: WICKET-1739
> URL: https://issues.apache.org/jira/browse/WICKET-1739
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.3.4
> Environment: Linux, Jetty 6.1.x
> Reporter: Martin Grigorov
> Assignee: Martin Grigorov
>
> With SVN r655308 MockWebApplication.processRequestCycle(Class, PageParameters) has been refactored and now each call to this method with non-home page's class as parameter calls "getServletRequest().setURL(path + url);" at line 452 (wicket 1.3.4). After this invocation all subsequent calls with this stack trace :
> Thread [main] (Suspended)
> MockHttpServletRequest.getRequestURI() line: 793
> MockWebApplication$1(WicketFilter).getRelativePath(HttpServletRequest) line: 452
> ServletWebRequest.getPath() line: 144
> WebRequestCodingStrategy.getRequestPath(Request) line: 988
> WebRequestCodingStrategy.decode(Request) line: 196
> ServletWebRequest(Request).getRequestParameters() line: 171
> MyPage(Page).init() line: 1167
> ...
> returns not just the path but the query string is appended too (e.g. /mount/path?someParam=value) and later on o.a.w.request/target/coding/AbstractRequestTargetUrlCodingStrategy#matches(String) returns false (because there is query string at the end) and thus it could not resolve the request target.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.