Hi.
I found a nice workaround for the testability of the Kendo UI
`AjaxDropDownList`.
It’s relatively easy. Just use a regular Kendo UI `DropDownList` and attach a
`AjaxFormComponentUpdatingBehavior`.
This will make the usual thing work like:
formTester.select(comp, index)
tester.executeAjaxEvent(dropDownComp, „change“)
Cheers,
Manfred
> Hi Manfred,
>
> AjaxDropDownList belongs to the kendoDropDownList widget, which can be
> triggered this way:
>
> var dropdownlist = $("#myDDL").data("kendoDropDownList"); // eq. to
> KendoUIBehavior.widget(myDDL, DropDownListBehavior.METHOD) in wicket
> dropdownlist.trigger("change"); // this will trigger change event
>
> I'm not sure it can be triggered like the regular (on)change event...
>
> Another option, maybe you can execute the OnChangeAjaxBehavior trough
> BaseWicketTester#executeBehavior(AbstractAjaxBehavior).
>
> Never tested, so hope this helps :)
> Sebastien.
>
>
> On Fri, Feb 17, 2017 at 6:44 PM, Manfred Bergmann <[hidden email]>
> wrote:
>
> > Hi.
> >
> > I've tried to get the AjaxDropDownList under test.
> > In a test I'm doing:
> > val formTester = tester.newFormTester("form")
> > formTester.select("cut:container:data.serviceType", <someservicetype>)
> > tester.executeAjaxEvent(basePath+":data.serviceType", "change")
> >
> > but the onSelectionChanged is never triggered in a test.
> > It works when starting the app in a browser.
> >
> > How can I make this testable?
> >
> >
> > Manfred
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]