@Test(expected = ApplicationException.class)
public void testRetryWorkflowNoTasks() {

    Workflow workflow = new Workflow();
    workflow.setWorkflowId("ApplicationException");
    workflow.setStatus(Workflow.WorkflowStatus.FAILED);
    workflow.setTasks(Collections.emptyList());
    when(executionDAOFacade.getWorkflowById(anyString(), anyBoolean())).thenReturn(workflow);
    workflowExecutor.retry(workflow.getWorkflowId());
}