assertTrue(taskRunManager.isRunning(task.getId()));
waitForTask(task);
assertFalse(taskRunManager.isRunning(task.getId()));
List<TaskRun> taskRuns = taskRunManager.findByTaskId(task.getId());
assertEquals(1, taskRuns.size());
TaskRun taskRun = taskRuns.get(0);
assertEquals(Status.SUCCESS, taskRun.getStatus());
// we slept so there should be no output at all
assertNull(taskRun.getStackTrace());
assertTrue(StringUtils.isEmpty(taskRun.getSysOut()));
assertTrue(StringUtils.isEmpty(taskRun.getSysErr()));
}