### Question:
DownloadStrategy { public boolean validFilenameFromStore(@NonNull DownloadTask task) { final String filename = OkDownload.with().breakpointStore() .getResponseFilename(task.getUrl()); if (filename == null) return false; task.getFilenameHolder().set(filename); return true; }  ResumeAvailableResponseCheck resumeAvailableResponseCheck(
            DownloadConnection.Connected connected,
            int blockIndex,
            BreakpointInfo info); int determineBlockCount(@NonNull DownloadTask task, long totalLength); long reuseIdledSameInfoThresholdBytes(); boolean inspectAnotherSameInfo(@NonNull DownloadTask task, @NonNull BreakpointInfo info,
                                          long instanceLength); boolean isUseMultiBlock(final boolean isAcceptRange); void inspectFilenameFromResume(@NonNull String filenameOnStore,
                                          @NonNull DownloadTask task); void validFilenameFromResponse(@Nullable String responseFileName,
                                          @NonNull DownloadTask task,
                                          @NonNull BreakpointInfo info); boolean validFilenameFromStore(@NonNull DownloadTask task); void validInfoOnCompleted(@NonNull DownloadTask task, @NonNull DownloadStore store); @Nullable ResumeFailedCause getPreconditionFailedCause(int responseCode,
                                                                  boolean isAlreadyProceed,
                                                                  @NonNull BreakpointInfo info,
                                                                  @Nullable String responseEtag); boolean isServerCanceled(int responseCode, boolean isAlreadyProceed); void inspectNetworkAvailable(); void inspectNetworkOnWifi(@NonNull DownloadTask task);  }### Answer:
@Test public void validFilenameFromStore() { final DownloadStrategy.FilenameHolder holder = new DownloadStrategy.FilenameHolder(); when(task.getUrl()).thenReturn("url"); when(task.getFilenameHolder()).thenReturn(holder); final BreakpointStore store = OkDownload.with().breakpointStore(); doReturn(null).when(store).getResponseFilename("url"); assertThat(strategy.validFilenameFromStore(task)).isFalse(); assertThat(holder.get()).isNull(); doReturn("filename").when(store).getResponseFilename("url"); assertThat(strategy.validFilenameFromStore(task)).isTrue(); assertThat(holder.get()).isEqualTo("filename"); }