Skip to content

Commit

Permalink
removed unsupported params
Browse files Browse the repository at this point in the history
  • Loading branch information
Pazus committed Dec 17, 2016
1 parent c66a395 commit 6857a59
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 24 deletions.
Expand Up @@ -105,16 +105,6 @@ public GetMatchHistoryRequestBuilder skill(Skill skill) {
return this;
}

public GetMatchHistoryRequestBuilder dateMin(Date dateMin) {
this.dateMin = dateMin.getTime() / 1000L;
return this;
}

public GetMatchHistoryRequestBuilder dateMax(Date dateMax) {
this.dateMax = dateMax.getTime() / 1000L;
return this;
}

public GetMatchHistoryRequestBuilder minPlayers(Integer minPlayers) {
this.minPlayers = minPlayers;
return this;
Expand Down Expand Up @@ -151,8 +141,6 @@ public GetMatchHistoryRequestBuilder tournamentGamesOnly(boolean tournamentGames
public static final String REQUEST_PARAM_HERO_ID = "hero_id";
public static final String REQUEST_PARAM_GAME_MODE = "game_mode";
public static final String REQUEST_PARAM_SKILL = "skill";
public static final String REQUEST_PARAM_DATE_MIN = "date_min";
public static final String REQUEST_PARAM_DATE_MAX = "date_max";
public static final String REQUEST_PARAM_MIN_PLAYERS = "min_players";
public static final String REQUEST_PARAM_ACCOUNT_ID = "account_id";
public static final String REQUEST_PARAM_LEAGUE_ID = "league_id";
Expand Down Expand Up @@ -189,14 +177,6 @@ public GetMatchHistoryRequest buildRequest() {
addParameter(REQUEST_PARAM_SKILL,skill.toString());
}

if (dateMin != null) {
addParameter(REQUEST_PARAM_DATE_MIN,dateMin);
}

if (dateMax != null) {
addParameter(REQUEST_PARAM_DATE_MAX,dateMax);
}

if (minPlayers != null) {
addParameter(REQUEST_PARAM_MIN_PLAYERS,minPlayers);
}
Expand Down
Expand Up @@ -33,8 +33,6 @@ public void testGetMatchHistoryRequestBuilder() {

GetMatchHistoryRequest request = new GetMatchHistoryRequestBuilder()
.accountId("123")
.dateMin(startDate.getTime())
.dateMax(endDate.getTime())
.gameMode(GetMatchHistoryRequest.GameMode.ALL_PICK)
.heroIdsFilter(heroIdsFilter)
.leagueId("5")
Expand All @@ -53,8 +51,6 @@ public void testGetMatchHistoryRequestBuilder() {
Map<String, String> parameters = request.getParameters();

assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_ACCOUNT_ID),"123");
assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_DATE_MIN),String.valueOf(startDate.getTimeInMillis()/1000L));
assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_DATE_MAX),String.valueOf(endDate.getTimeInMillis()/1000L));
assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_GAME_MODE),"1");
assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_HERO_ID),"1,2");
assertEquals(parameters.get(GetMatchHistoryRequestBuilder.REQUEST_PARAM_LEAGUE_ID),"5");
Expand Down

0 comments on commit 6857a59

Please sign in to comment.