### Question:
CallbackDispatcher { public boolean isFetchProcessMoment(DownloadTask task) { final long minInterval = task.getMinIntervalMillisCallbackProcess(); final long now = SystemClock.uptimeMillis(); return minInterval <= 0 || now - DownloadTask.TaskHideWrapper .getLastCallbackProcessTs(task) >= minInterval; } CallbackDispatcher(@NonNull Handler handler, @NonNull DownloadListener transmit);  CallbackDispatcher(); boolean isFetchProcessMoment(DownloadTask task); void endTasksWithError(@NonNull final Collection<DownloadTask> errorCollection,
                                  @NonNull final Exception realCause); void endTasks(@NonNull final Collection<DownloadTask> completedTaskCollection,
                         @NonNull final Collection<DownloadTask> sameTaskConflictCollection,
                         @NonNull final Collection<DownloadTask> fileBusyCollection); void endTasksWithCanceled(@NonNull final Collection<DownloadTask> canceledCollection); DownloadListener dispatch();  }### Answer:
@Test public void isFetchProcessMoment_noMinInterval() { final DownloadTask task = mock(DownloadTask.class); when(task.getMinIntervalMillisCallbackProcess()).thenReturn(0); assertThat(dispatcher.isFetchProcessMoment(task)).isTrue(); }
@Test public void isFetchProcessMoment_largeThanMinInterval() { final DownloadTask task = mock(DownloadTask.class); when(task.getMinIntervalMillisCallbackProcess()).thenReturn(1); assertThat(dispatcher.isFetchProcessMoment(task)).isTrue(); }
@Test public void isFetchProcessMoment_lessThanMinInterval() { final DownloadTask task = mock(DownloadTask.class); when(task.getMinIntervalMillisCallbackProcess()).thenReturn(Integer.MAX_VALUE); assertThat(dispatcher.isFetchProcessMoment(task)).isFalse(); }