GetUserDetails extends UseCase { @Override protected Observable buildUseCaseObservable() { return this.userRepository.user(this.userId); } GetUserDetails(Context appContext);  GetUserDetails(int userId, Context appContext);  GetUserDetails(int userId, UserRepository userRepository); void setUserRepository(UserRepository userRepository); int getUserId(); void setUserId(int userId);  }
@Test public void testGetUserDetailsUseCaseObservableHappyCase() { getUserDetails.buildUseCaseObservable(); verify(mockUserRepository).user(FAKE_USER_ID); verifyNoMoreInteractions(mockUserRepository); verifyZeroInteractions(mockPostExecutionThread); verifyZeroInteractions(mockThreadExecutor); }