TeamsRepository { public Observable<Team> getTeam(String flag) { return teamsLocalDataSource.teamEntity(flag).map(teamEntityToTeamMapper::map); } TeamsRepository(@NonNull TeamsLocalDataSource teamsLocalDataSource, @NonNull TeamEntityToTeamMapper teamEntityToTeamMapper); Observable<List<Team>> getTeamList(); Observable<Team> getTeam(String flag);  }
@Test public void givenATeamEntityByFlagFromLocalApi() { given(teamsLocalDataSource.teamEntity(ANY_FLAG_OF_TEAM_ENTITY)).willReturn(Observable.just(FakeTeamLocalAPI.getFakeTeamEntity())); teamsRepository.getTeam(ANY_FLAG_OF_TEAM_ENTITY); verify(teamsLocalDataSource).teamEntity(ANY_FLAG_OF_TEAM_ENTITY); }