-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Introducing a filter parameter on the "items" endpoint #7
Conversation
You can also use the "f" parameter to pass the requested format to the request for convenience ; below | ||
is the list of possible values: | ||
|
||
* json | ||
* geojson | ||
* shapefile | ||
* csv | ||
* ooxml | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unrelated, but was discussed during the weekly on 4th sept.
@Test | ||
public void testGetItemsWithFilter() { | ||
MockHttpServletRequest actualRequest = (MockHttpServletRequest) req.getNativeRequest(); | ||
actualRequest.addHeader("Accept", "application/json"); | ||
ResponseEntity<FeatureCollection> response = collectionsApi.getFeatures("locations", -1, | ||
null, null, "number = 140"); | ||
|
||
assertThat(response.getBody().getFeatures().toList().size()) | ||
.isEqualTo(1); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this test fails on the "sample-data" spring profile but works fine when using the "postgis" one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding comments to explain some changes.
efd708f
to
5029681
Compare
…profile Also adding a application.yml on the test classpath to make test config easier.
5029681
to
c5d3225
Compare
No description provided.