FailoverService { public void updateFailoverComplete(final List<Integer> items) { for (int each : items) { jobNodeStorage.removeJobNodeIfExisted(FailoverNode.getExecutionFailoverNode(each)); } } FailoverService(final CoordinatorRegistryCenter coordinatorRegistryCenter, final JobConfiguration jobConfiguration); void setCrashedFailoverFlag(final int item); void failoverIfNecessary(); void updateFailoverComplete(final List<Integer> items); List<Integer> getLocalHostFailoverItems(); List<Integer> getLocalHostTakeOffItems(); void removeFailoverInfo();  }
@Test public void assertUpdateFailoverComplete() { failoverService.updateFailoverComplete(Arrays.asList(0, 1)); verify(jobNodeStorage).removeJobNodeIfExisted("execution/0/failover"); verify(jobNodeStorage).removeJobNodeIfExisted("execution/1/failover"); }