UseCase { public void execute(REQUEST_DATA requestData, Subscriber<RESPONSE_DATA> useCaseSubscriber) { this.subscription.add(this.buildObservable(requestData) .subscribeOn(threadScheduler) .observeOn(postExecutionScheduler) .subscribe(useCaseSubscriber)); repository.register(this); } UseCase(REPOSITORY repository,
                   Messenger messenger,
                   @Named("Thread") Scheduler threadScheduler,
                   @Named("PostExecution") Scheduler postExecutionScheduler); void execute(REQUEST_DATA requestData, Subscriber<RESPONSE_DATA> useCaseSubscriber); boolean isUnsubscribed(); void unsubscribe();  }
@Test @SuppressWarnings("unchecked") public void buildUseCaseObservable_AsCorrectResult() { useCase.execute(testSubscriber); assertThat(testSubscriber.getOnNextEvents().size(), is(0)); }