@Test
/**
 * Kill map attempt for succeeded map task
 * {@link TaskState#SUCCEEDED}->{@link TaskState#SCHEDULED}

 */
public void testKillAttemptForSuccessfulTask() {
  LOG.info("--- START: testKillAttemptForSuccessfulTask ---");
  mockTask = createMockTask(TaskType.MAP);
  TaskId taskId = getNewTaskID();
  scheduleTaskAttempt(taskId);
  launchTaskAttempt(getLastAttempt().getAttemptId());
  commitTaskAttempt(getLastAttempt().getAttemptId());
  mockTask.handle(new TaskTAttemptEvent(getLastAttempt().getAttemptId(),
      TaskEventType.T_ATTEMPT_SUCCEEDED));
  assertTaskSucceededState();
  mockTask.handle(
      new TaskTAttemptKilledEvent(getLastAttempt().getAttemptId(), true));
  assertEquals(TaskAttemptEventType.TA_RESCHEDULE,
      taskAttemptEventHandler.lastTaskAttemptEvent.getType());
  assertTaskScheduledState();
}