@Test public void testGetUserEntityListError() { cloudUserDataStore.getUsersEntityList(mockUserListDataStoreCallback); verify(mockRestApi).getUserList(restApiUserListCallbackArgumentCaptor.capture()); verifyZeroInteractions(mockUserListDataStoreCallback); restApiUserListCallbackArgumentCaptor.getValue().onError(any(Exception.class)); verify(mockUserListDataStoreCallback).onError(any(Exception.class)); verifyZeroInteractions(mockUserCache); }
@Override public void getUsersEntityList(final UserListCallback userListCallback) { this.restApi.getUserList(new RestApi.UserListCallback() { @Override public void onUserListLoaded(Collection<UserEntity> usersCollection) { userListCallback.onUserListLoaded(usersCollection); } @Override public void onError(Exception exception) { userListCallback.onError(exception); } }); }
CloudUserDataStore implements UserDataStore { @Override public void getUsersEntityList(final UserListCallback userListCallback) { this.restApi.getUserList(new RestApi.UserListCallback() { @Override public void onUserListLoaded(Collection<UserEntity> usersCollection) { userListCallback.onUserListLoaded(usersCollection); } @Override public void onError(Exception exception) { userListCallback.onError(exception); } }); } }
CloudUserDataStore implements UserDataStore { @Override public void getUsersEntityList(final UserListCallback userListCallback) { this.restApi.getUserList(new RestApi.UserListCallback() { @Override public void onUserListLoaded(Collection<UserEntity> usersCollection) { userListCallback.onUserListLoaded(usersCollection); } @Override public void onError(Exception exception) { userListCallback.onError(exception); } }); }  }
CloudUserDataStore implements UserDataStore { @Override public void getUsersEntityList(final UserListCallback userListCallback) { this.restApi.getUserList(new RestApi.UserListCallback() { @Override public void onUserListLoaded(Collection<UserEntity> usersCollection) { userListCallback.onUserListLoaded(usersCollection); } @Override public void onError(Exception exception) { userListCallback.onError(exception); } }); }  @Override void getUsersEntityList(final UserListCallback userListCallback); @Override void getUserEntityDetails(int id,
                                     final UserDetailsCallback userDetailsCallback); }
CloudUserDataStore implements UserDataStore { @Override public void getUsersEntityList(final UserListCallback userListCallback) { this.restApi.getUserList(new RestApi.UserListCallback() { @Override public void onUserListLoaded(Collection<UserEntity> usersCollection) { userListCallback.onUserListLoaded(usersCollection); } @Override public void onError(Exception exception) { userListCallback.onError(exception); } }); }  @Override void getUsersEntityList(final UserListCallback userListCallback); @Override void getUserEntityDetails(int id,
                                     final UserDetailsCallback userDetailsCallback);  }