As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
@Rule public ActivitiRule activitiRule = new ActivitiRule(); @Test @Deployment(resources = {"org/activiti/test/my-process.bpmn20.xml"}) public void test() { TaskService taskService = activitiRule.getTaskService(); Task task = taskService.newTask(); taskService.saveTask(task); List<Task> tasks = taskService.createTaskQuery().or().taskId(task.getId()).processDefinitionKey("xyz").endOr().list(); assertTrue(!tasks.isEmpty()); }