### Question:
PendingResultHandler { public String createPendingResult() { return pendingResultsHolder.create(); } @Autowired  PendingResultHandler(final PendingResultsHolder pendingResultsHolder,
            @Value("${server.application.name}") final String applicationName); String createPendingResult(); void removePendingResult(final String pendingResultId); Object pollValue(final String pendingResultId); void offerValue(final String pendingResultId, final Object value); void offerException(final String pendingResultId, final Exception exception);  }### Answer:
@Test public void shouldCreatePendingResult() { final String pendingResultId = randomId(); when(mockPendingResultsHolder.create()).thenReturn(pendingResultId); final String returnedId = pendingResultHandler.createPendingResult(); assertEquals(pendingResultId, returnedId); }