### Question:
SimplePendingResult extends PendingResult<Status> { @Override public void setResultCallback(@NonNull ResultCallback callback) { if (hasResult) { callback.onResult(generateStatus()); } } SimplePendingResult(boolean hasResult); @NonNull @Override Status await(); @NonNull @Override Status await(long time, @NonNull TimeUnit timeUnit); @Override void cancel(); @Override boolean isCanceled(); @Override void setResultCallback(@NonNull ResultCallback callback); @Override void setResultCallback(@NonNull ResultCallback callback, long time,
      @NonNull TimeUnit timeUnit);  }### Answer:
@Test public void setResultCallback_shouldReturnSuccess() { TestResultCallback callback = new TestResultCallback(); result.setResultCallback(callback); assertThat(callback.getStatus().getStatusCode()).isEqualTo(Status.SUCCESS); }
@Test public void setResultCallback_delay_shouldReturnSuccess() { TestResultCallback callback = new TestResultCallback(); result.setResultCallback(callback, 1000, TimeUnit.MILLISECONDS); assertThat(callback.getStatus().getStatusCode()).isEqualTo(Status.SUCCESS); }