RetryableLineMessagingClientImpl implements RetryableLineMessagingClient { @Override public CompletableFuture<BotApiResponse> narrowcast(final UUID retryKey, final Narrowcast narrowcast) { return toBotApiResponseFuture(retrofitImpl.narrowcast(retryKey.toString(), narrowcast)); }  @Override CompletableFuture<BotApiResponse> pushMessage(final UUID retryKey, final PushMessage pushMessage); @Override CompletableFuture<BotApiResponse> multicast(final UUID retryKey, final Multicast multicast); @Override CompletableFuture<BotApiResponse> broadcast(final UUID retryKey, final Broadcast broadcast); @Override CompletableFuture<BotApiResponse> narrowcast(final UUID retryKey, final Narrowcast narrowcast);  }
@Test public void narrowcast() { UUID retryKey = UUID.randomUUID(); whenCall(retrofitMock.narrowcast(any(String.class), any(Narrowcast.class)), BOT_API_SUCCESS_RESPONSE_BODY); final Narrowcast narrowcast = new Narrowcast( new TextMessage("text"), Filter.builder() .demographic( GenderDemographicFilter.builder() .oneOf(singletonList(Gender.FEMALE)) .build() ).build()); final BotApiResponse botApiResponse = target.narrowcast(retryKey, narrowcast).join(); verify(retrofitMock).narrowcast(retryKey.toString(), narrowcast); assertThat(botApiResponse).isEqualTo(BOT_API_SUCCESS_RESPONSE); }