Package org.jbpm.formbuilder.shared.task

Examples of org.jbpm.formbuilder.shared.task.TaskRef


    //test happy path without filtering param for RESTIoService.getIoAssociations(...)
    public void testGetIoAssociationsNoQParam() throws Exception {
        RESTIoService restService = new RESTIoService();
        TaskDefinitionService taskService = EasyMock.createMock(TaskDefinitionService.class);
        List<TaskRef> tasks = new ArrayList<TaskRef>();
        tasks.add(new TaskRef());
        tasks.add(new TaskRef());
        EasyMock.expect(taskService.query(EasyMock.eq("somePackage"), EasyMock.eq(""))).andReturn(tasks).once();
        restService.setTaskService(taskService);
        ServletContext context = EasyMock.createMock(ServletContext.class);
       
        EasyMock.replay(taskService, context);
View Full Code Here


    //test happy path for RESTIoService.getIoAssociations(...)
    public void testGetIoAssociationOK() throws Exception {
        RESTIoService restService = new RESTIoService();
        TaskDefinitionService taskService = EasyMock.createMock(TaskDefinitionService.class);
        List<TaskRef> tasks = new ArrayList<TaskRef>();
        tasks.add(new TaskRef());
        EasyMock.expect(taskService.getTasksByName(
                EasyMock.eq("somePackage"), EasyMock.eq("someProcess"), EasyMock.eq("someTask"))).andReturn(tasks).once();
        restService.setTaskService(taskService);
        ServletContext context = EasyMock.createMock(ServletContext.class);
       
View Full Code Here

        EasyMock.expect(view.addMessage(EasyMock.eq(processText), EasyMock.eq(processId))).
            andReturn(toolreg).once();
        EasyMock.expect(view.addMessage(EasyMock.eq(taskText), EasyMock.eq(taskName))).
            andReturn(toolreg).once();

        TaskRef ioRef = new TaskRef();
        ioRef.setPackageName(packageName);
        ioRef.setProcessId(processId);
        ioRef.setTaskId(taskName);
       
        EasyMock.replay(view, res, toolreg, i18n);
        new ToolBarPresenter(view);
        bus.fireEvent(new TaskSelectedEvent(ioRef));
        EasyMock.verify(view, res, toolreg, i18n);
View Full Code Here

            andReturn(toolreg).once();

        toolreg.remove();
        EasyMock.expectLastCall().times(3);
       
        TaskRef ioRef = new TaskRef();
        ioRef.setPackageName(packageName);
        ioRef.setProcessId(processId);
        ioRef.setTaskId(taskName);
       
        EasyMock.replay(view, res, toolreg, i18n);
        new ToolBarPresenter(view);
        bus.fireEvent(new TaskSelectedEvent(ioRef));
        bus.fireEvent(new TaskSelectedEvent(null));
View Full Code Here

import org.jbpm.formbuilder.shared.task.TaskRef;

public class FormDefinitionServiceTest extends TestCase {

    public void testTemplateFormFromTask() throws Exception {
        TaskRef task = new TaskRef();
        task.setTaskId("MyTask");
        FormDefinitionService formService = new MockFormDefinitionService();
        FormRepresentation form = formService.createFormFromTask(task);
        assertNotNull("form shouldn't be null", form);
        assertTrue("form should contain two items", form.getFormItems().size() == 2);
    }
View Full Code Here

TOP

Related Classes of org.jbpm.formbuilder.shared.task.TaskRef

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.