Uploaded image for project: 'camunda BPM'
  1. camunda BPM
  2. CAM-10012

TaskService returns null Task for SpringRunner

XMLWordPrintable

    • Icon: Bug Report Bug Report
    • Resolution: Cannot Reproduce
    • Icon: L3 - Default L3 - Default
    • None
    • 7.8.13
    • bpmn model api
    • None
    • BPMN

      @RunWith(SpringRunner.class)
      @ContextConfiguration(locations = "/applicationContext_forNetworkSlicing.xml")
      public class ProcessServiceInstantiationFeasibilitySuccessTest {

      @Autowired
      private RuntimeService runtimeService;

      @Autowired
      @Rule
      public ProcessEngineRule processEngineRule;

      @Test
      @Deployment(resources =

      {"process/ProcessServiceInstantiationFeasibility.bpmn"}

      )
      public void serviceInstantiationFeasibilitySuccess() {
      // given
      BpmnAwareTests.init(processEngineRule.getProcessEngine());
      Map<String, Object> variables = new HashMap<>();
      variables.put("id","42");
      variables.put("href","http://serverlocation:port/orderManagement/serviceOrder/42");

      // when
      ProcessInstance instance = runtimeService
      .startProcessInstanceByKey("ProcessServiceInstantiationFeasibility", "businessKey", variables);

      TaskService taskService = processEngineRule.getTaskService();
      Task task = taskService.createTaskQuery().singleResult();
      assertEquals("Validate Incoming Request", task.getName());

      Here task is null always. Why?

        This is the controller panel for Smart Panels app

          1. BPMN.jpg
            43 kB
            Mahesh Poojary

              yana.vasileva Yana Vasileva
              maheshps Mahesh Poojary
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: