@Test
public void getMappedTasks() throws Exception {

    WorkflowTask taskToSchedule = new WorkflowTask();
    taskToSchedule.setName("json_jq_transform_task");
    taskToSchedule.setType(TaskType.JSON_JQ_TRANSFORM.name());
    taskToSchedule.setTaskDefinition(new TaskDef("json_jq_transform_task"));
    Map<String, Object> taskInput = new HashMap<>();
    taskInput.put("in1", new String[] {"a", "b"});
    taskInput.put("in2", new String[] {"c", "d"});
    taskInput.put("queryExpression", "{ out: (.in1 + .in2) }");
    taskToSchedule.setInputParameters(taskInput);
    String taskId = IDGenerator.generate();
    WorkflowDef  wd = new WorkflowDef();
    Workflow w = new Workflow();
    w.setWorkflowDefinition(wd);
    TaskMapperContext taskMapperContext = TaskMapperContext.newBuilder()
            .withWorkflowDefinition(wd)
            .withWorkflowInstance(w)
            .withTaskDefinition(new TaskDef())
            .withTaskToSchedule(taskToSchedule)
            .withTaskInput(taskInput)
            .withRetryCount(0)
            .withTaskId(taskId)
            .build();
    List<Task> mappedTasks = new JsonJQTransformTaskMapper(parametersUtils, metadataDAO).getMappedTasks(taskMapperContext);
    assertEquals(1, mappedTasks.size());
    assertNotNull(mappedTasks);
    assertEquals(TaskType.JSON_JQ_TRANSFORM.name(), mappedTasks.get(0).getTaskType());
}