Search in sources :

Example 1 with DispatcherStub

use of org.activityinfo.ui.client.dispatch.DispatcherStub in project activityinfo by bedatadriven.

the class SiteAdminTreeLoaderTest method load.

@Test
public void load() {
    DispatcherStub dispatcher = new DispatcherStub();
    dispatcher.setResult(new GetSchema(), DTOs.PEAR.SCHEMA);
    dispatcher.setResult(new GetAdminEntities(1), DTOs.PROVINCES);
    SiteAdminTreeLoader loader = new SiteAdminTreeLoader(dispatcher, new AdminGroupingModel(1));
    new TreeStore<ModelData>(loader);
    loader.load();
}
Also used : AdminGroupingModel(org.activityinfo.ui.client.page.entry.grouping.AdminGroupingModel) TreeStore(com.extjs.gxt.ui.client.store.TreeStore) DispatcherStub(org.activityinfo.ui.client.dispatch.DispatcherStub) GetAdminEntities(org.activityinfo.legacy.shared.command.GetAdminEntities) GetSchema(org.activityinfo.legacy.shared.command.GetSchema) Test(org.junit.Test)

Aggregations

TreeStore (com.extjs.gxt.ui.client.store.TreeStore)1 GetAdminEntities (org.activityinfo.legacy.shared.command.GetAdminEntities)1 GetSchema (org.activityinfo.legacy.shared.command.GetSchema)1 DispatcherStub (org.activityinfo.ui.client.dispatch.DispatcherStub)1 AdminGroupingModel (org.activityinfo.ui.client.page.entry.grouping.AdminGroupingModel)1 Test (org.junit.Test)1