final int numSlotsPerTask = 2;
maps = new TaskInProgress[1];
reduces = new TaskInProgress[1];
maps[0] = new FakeTaskInProgress(getJobID(), "test",
JobSplit.EMPTY_TASK_SPLIT,
jobtracker, getJobConf(), this, 0, numSlotsPerTask);
TaskAttemptID attemptId = new TaskAttemptID(maps[0].getTIPId(), 0);
// make this task a taskCleanup task of a map task
mapCleanupTasks.add(attemptId);
TaskStatus stat = new MapTaskStatus(attemptId, 0.01f, 2,
TaskStatus.State.FAILED_UNCLEAN, "", "", trackers[0],
TaskStatus.Phase.MAP, new Counters());
maps[0].updateStatus(stat);
//similarly for reduce task's taskCleanup task
reduces[0] = new FakeTaskInProgress(getJobID(), "test", 1,
0, jobtracker, getJobConf(), this, numSlotsPerTask);
attemptId = new TaskAttemptID(reduces[0].getTIPId(), 0);
// make this task a taskCleanup task of a reduce task
reduceCleanupTasks.add(attemptId);