You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "vineet semwal (Created) (JIRA)" <ji...@apache.org> on 2012/01/07 11:07:40 UTC
[jira] [Created] (WICKET-4327) wickettester should have
getajaxrequestarget
wickettester should have getajaxrequestarget
--------------------------------------------
Key: WICKET-4327
URL: https://issues.apache.org/jira/browse/WICKET-4327
Project: Wicket
Issue Type: New Feature
Affects Versions: 1.5.3
Environment: wicket 1.5.3
Reporter: vineet semwal
currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
it can be done easily by saving the target in ART.respond(requestcycle) in some global object foreg.i did this in local wicket copy
public enum LastAjaxTarget {
INSTANCE;
public AjaxRequestTarget getTarget() {
return target;
}
public void setTarget(AjaxRequestTarget target) {
this.target = target;
}
AjaxRequestTarget target;
}
and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
thanks
Vineet Semwal
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-4327) wickettester should have
getajaxrequestarget
Posted by "Martin Grigorov (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-4327?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13181962#comment-13181962 ]
Martin Grigorov commented on WICKET-4327:
-----------------------------------------
You can save the ART in your own IRequestCycleListener.
Override org.apache.wicket.request.cycle.IRequestCycleListener#onRequestHandlerResolved() and save it.
tester.getApplication().getRequestCycleListeners().add(yourListener);
later:
ART target = yourListener.getART();
> wickettester should have getajaxrequestarget
> --------------------------------------------
>
> Key: WICKET-4327
> URL: https://issues.apache.org/jira/browse/WICKET-4327
> Project: Wicket
> Issue Type: New Feature
> Affects Versions: 1.5.3
> Environment: wicket 1.5.3
> Reporter: vineet semwal
>
> currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
> it can be done easily by saving the target in ART.respond(requestcycle) in some object foreg.i did this in local wicket copy
> public enum LastAjaxTarget {
> INSTANCE;
> public AjaxRequestTarget getTarget() {
> return target;
> }
> public void setTarget(AjaxRequestTarget target) {
> this.target = target;
> }
> AjaxRequestTarget target;
> }
> and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
> thanks
> Vineet Semwal
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (WICKET-4327) wickettester should have
getajaxrequestarget
Posted by "vineet semwal (Updated) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-4327?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
vineet semwal updated WICKET-4327:
----------------------------------
Description:
currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
it can be done easily by saving the target in ART.respond(requestcycle) in some object foreg.i did this in local wicket copy
public enum LastAjaxTarget {
INSTANCE;
public AjaxRequestTarget getTarget() {
return target;
}
public void setTarget(AjaxRequestTarget target) {
this.target = target;
}
AjaxRequestTarget target;
}
and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
thanks
Vineet Semwal
was:
currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
it can be done easily by saving the target in ART.respond(requestcycle) in some global object foreg.i did this in local wicket copy
public enum LastAjaxTarget {
INSTANCE;
public AjaxRequestTarget getTarget() {
return target;
}
public void setTarget(AjaxRequestTarget target) {
this.target = target;
}
AjaxRequestTarget target;
}
and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
thanks
Vineet Semwal
> wickettester should have getajaxrequestarget
> --------------------------------------------
>
> Key: WICKET-4327
> URL: https://issues.apache.org/jira/browse/WICKET-4327
> Project: Wicket
> Issue Type: New Feature
> Affects Versions: 1.5.3
> Environment: wicket 1.5.3
> Reporter: vineet semwal
>
> currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
> it can be done easily by saving the target in ART.respond(requestcycle) in some object foreg.i did this in local wicket copy
> public enum LastAjaxTarget {
> INSTANCE;
> public AjaxRequestTarget getTarget() {
> return target;
> }
> public void setTarget(AjaxRequestTarget target) {
> this.target = target;
> }
> AjaxRequestTarget target;
> }
> and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
> thanks
> Vineet Semwal
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-4327) wickettester should have
getajaxrequestarget
Posted by "Martin Grigorov (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-4327?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13181921#comment-13181921 ]
Martin Grigorov commented on WICKET-4327:
-----------------------------------------
One more example that https://issues.apache.org/jira/browse/WICKET-4326 will make it easier for such cases.
With IAjaxRequestHandler you will be able to setup custom one with org.apache.wicket.protocol.http.WebApplication#setAjaxRequestTargetProvider() and override its add() method to collect what you have added.
> wickettester should have getajaxrequestarget
> --------------------------------------------
>
> Key: WICKET-4327
> URL: https://issues.apache.org/jira/browse/WICKET-4327
> Project: Wicket
> Issue Type: New Feature
> Affects Versions: 1.5.3
> Environment: wicket 1.5.3
> Reporter: vineet semwal
>
> currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
> it can be done easily by saving the target in ART.respond(requestcycle) in some object foreg.i did this in local wicket copy
> public enum LastAjaxTarget {
> INSTANCE;
> public AjaxRequestTarget getTarget() {
> return target;
> }
> public void setTarget(AjaxRequestTarget target) {
> this.target = target;
> }
> AjaxRequestTarget target;
> }
> and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
> thanks
> Vineet Semwal
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (WICKET-4327) wickettester should have
getajaxrequestarget
Posted by "Martin Grigorov (Resolved) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-4327?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov resolved WICKET-4327.
-------------------------------------
Resolution: Duplicate
> wickettester should have getajaxrequestarget
> --------------------------------------------
>
> Key: WICKET-4327
> URL: https://issues.apache.org/jira/browse/WICKET-4327
> Project: Wicket
> Issue Type: New Feature
> Affects Versions: 1.5.3
> Environment: wicket 1.5.3
> Reporter: vineet semwal
>
> currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
> it can be done easily by saving the target in ART.respond(requestcycle) in some object foreg.i did this in local wicket copy
> public enum LastAjaxTarget {
> INSTANCE;
> public AjaxRequestTarget getTarget() {
> return target;
> }
> public void setTarget(AjaxRequestTarget target) {
> this.target = target;
> }
> AjaxRequestTarget target;
> }
> and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
> thanks
> Vineet Semwal
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-4327) wickettester should have
getajaxrequestarget
Posted by "vineet semwal (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-4327?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13182107#comment-13182107 ]
vineet semwal commented on WICKET-4327:
---------------------------------------
martin-g:somehow that doesnt work,i see other handlers getting resolved but not ajaxrequesttarget so i added new AjaxRequestTarget.IListener in tester,.getApplication().getAjaxRequestTargetListeners().add(listener) and it worked,thanks for the advice..
> wickettester should have getajaxrequestarget
> --------------------------------------------
>
> Key: WICKET-4327
> URL: https://issues.apache.org/jira/browse/WICKET-4327
> Project: Wicket
> Issue Type: New Feature
> Affects Versions: 1.5.3
> Environment: wicket 1.5.3
> Reporter: vineet semwal
>
> currently wickettester doesnt have something like getAjaxrequesttarget() ,its needed for the case where you have to test the components added in ART,
> it can be done easily by saving the target in ART.respond(requestcycle) in some object foreg.i did this in local wicket copy
> public enum LastAjaxTarget {
> INSTANCE;
> public AjaxRequestTarget getTarget() {
> return target;
> }
> public void setTarget(AjaxRequestTarget target) {
> this.target = target;
> }
> AjaxRequestTarget target;
> }
> and in ART.respond(requestcycle), i just call the setter and provides the current ART , so wickettester or anything can access the LastAjaxTarget..
> thanks
> Vineet Semwal
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira