@Test public void shouldBuildQueryWithBefore() throws Exception { QueryParameters queryParameters = new QueryParametersBuilder(). withBefore("beforeId").createQueryParameters(); String expectedQuery = "?all=false&size=false&before=beforeId"; assertThat(queryParameters.toQuery(), equalTo(expectedQuery)); }
public String toQuery() { return query; }
QueryParameters { public String toQuery() { return query; } }
QueryParameters { public String toQuery() { return query; } QueryParameters();  QueryParameters(boolean all, String since, String before, boolean size, int limit, Map<String, String> filters); }
QueryParameters { public String toQuery() { return query; } QueryParameters();  QueryParameters(boolean all, String since, String before, boolean size, int limit, Map<String, String> filters); boolean isAll(); Optional<String> getSince(); Optional<String> getBefore(); boolean isSize(); int getLimit(); Map<String, String> getFilters(); String toQuery(); }
QueryParameters { public String toQuery() { return query; } QueryParameters();  QueryParameters(boolean all, String since, String before, boolean size, int limit, Map<String, String> filters); boolean isAll(); Optional<String> getSince(); Optional<String> getBefore(); boolean isSize(); int getLimit(); Map<String, String> getFilters(); String toQuery();  }