### Question:
DownloadCall extends NamedRunnable implements Comparable<DownloadCall> { @SuppressFBWarnings(value = "Eq", justification = "This special case is just for task priority") @Override public int compareTo(@NonNull DownloadCall o) { return o.getPriority() - getPriority(); } private  DownloadCall(DownloadTask task, boolean asyncExecuted, @NonNull DownloadStore store);   DownloadCall(DownloadTask task, boolean asyncExecuted,
                 @NonNull ArrayList<DownloadChain> runningBlockList,
                 @NonNull DownloadStore store); static DownloadCall create(DownloadTask task, boolean asyncExecuted,
                                      @NonNull DownloadStore store); boolean cancel(); boolean isCanceled(); boolean isFinishing(); @Override void execute(); boolean equalsTask(@NonNull DownloadTask task); @Nullable File getFile(); @SuppressFBWarnings(value = "Eq", justification = "This special case is just for task priority") @Override int compareTo(@NonNull DownloadCall o); final DownloadTask task; final boolean asyncExecuted; }### Answer:
@Test public void compareTo() { final DownloadCall compareCall = mock(DownloadCall.class); when(compareCall.getPriority()).thenReturn(6); when(call.getPriority()).thenReturn(3); final int result = call.compareTo(compareCall); assertThat(result).isEqualTo(3); }