Skip to content
Permalink
Browse files

Unit test for feature info geometry filter

  • Loading branch information
mhugent committed Jun 24, 2017
1 parent 77b9b1a commit ef8e58bcc291f774374bb0a9260d42f9c9903d4c
@@ -125,6 +125,15 @@ def test_project_wms(self):
'query_layers=testlayer%20%C3%A8%C3%A9&' +
'FEATURE_COUNT=10&FILTER=testlayer%20%C3%A8%C3%A9' + urllib.parse.quote(':"NAME" = \'two\' OR "utf8nameè" = \'three èé↓\''),
'wms_getfeatureinfo_filter_or_utf8')

# Test feature info request with filter geometry
self.wms_request_compare('GetFeatureInfo',
'&layers=testlayer%20%C3%A8%C3%A9&' +
'INFO_FORMAT=text%2Fxml&' +
'width=600&height=400&srs=EPSG%3A3857&' +
'query_layers=testlayer%20%C3%A8%C3%A9&' +
'FEATURE_COUNT=10&FILTER_GEOM=POLYGON((8.2035381 44.901459,8.2035562 44.901459,8.2035562 44.901418,8.2035381 44.901418,8.2035381 44.901459))',
'wms_getfeatureinfo_geometry_filter')

# Test DescribeLayer
self.wms_request_compare('DescribeLayer',
@@ -0,0 +1,14 @@
Content-Length: 261
Content-Type: text/xml; charset=utf-8

<GetFeatureInfoResponse>
<Layer name="testlayer èé">
<Feature id="1">
<Attribute name="id" value="2"/>
<Attribute name="name" value="two"/>
<Attribute name="utf8nameè" value="two àò"/>
<BoundingBox CRS="EPSG:3857" minx="913214.6741" maxx="913214.6741" miny="5606017.8743" maxy="5606017.8743"/>
<Attribute name="geometry" value="Point (913214.6741 5606017.8743)" type="derived"/>
</Feature>
</Layer>
</GetFeatureInfoResponse>

0 comments on commit ef8e58b

Please sign in to comment.
You can’t perform that action at this time.