Skip to content

Commit

Permalink
processing mean coordinates test
Browse files Browse the repository at this point in the history
  • Loading branch information
ghtmtt authored and m-kuhn committed Jan 13, 2017
1 parent 2c66493 commit 7958db2
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<GMLFeatureClassList>
<GMLFeatureClass>
<Name>mean_coordinates</Name>
<ElementPath>mean_coordinates</ElementPath>
<!--POINT-->
<GeometryType>1</GeometryType>
<SRSName>EPSG:4326</SRSName>
<DatasetSpecificInfo>
<FeatureCount>1</FeatureCount>
<ExtentXMin>3.33333</ExtentXMin>
<ExtentXMax>3.33333</ExtentXMax>
<ExtentYMin>0.11111</ExtentYMin>
<ExtentYMax>0.11111</ExtentYMax>
</DatasetSpecificInfo>
<PropertyDefn>
<Name>MEAN_X</Name>
<ElementPath>MEAN_X</ElementPath>
<Type>Real</Type>
</PropertyDefn>
<PropertyDefn>
<Name>MEAN_Y</Name>
<ElementPath>MEAN_Y</ElementPath>
<Type>Real</Type>
</PropertyDefn>
<PropertyDefn>
<Name>UID</Name>
<ElementPath>UID</ElementPath>
<Type>String</Type>
<Width>12</Width>
</PropertyDefn>
</GMLFeatureClass>
</GMLFeatureClassList>
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8" ?>
<ogr:FeatureCollection
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=""
xmlns:ogr="http://ogr.maptools.org/"
xmlns:gml="http://www.opengis.net/gml">
<gml:boundedBy>
<gml:Box>
<gml:coord><gml:X>3.333333333333333</gml:X><gml:Y>0.1111111111111111</gml:Y></gml:coord>
<gml:coord><gml:X>3.333333333333333</gml:X><gml:Y>0.1111111111111111</gml:Y></gml:coord>
</gml:Box>
</gml:boundedBy>

<gml:featureMember>
<ogr:mean_coordinates fid="mean_coordinates.0">
<ogr:geometryProperty><gml:Point srsName="EPSG:4326"><gml:coordinates>3.33333333333333,0.111111111111111</gml:coordinates></gml:Point></ogr:geometryProperty>
<ogr:MEAN_X>3.333333333333333</ogr:MEAN_X>
<ogr:MEAN_Y>0.111111111111111</ogr:MEAN_Y>
<ogr:UID>Single class</ogr:UID>
</ogr:mean_coordinates>
</gml:featureMember>
</ogr:FeatureCollection>
11 changes: 11 additions & 0 deletions python/plugins/processing/tests/testdata/qgis_algorithm_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2191,3 +2191,14 @@ tests:
OUTPUT:
name: expected/points_alog_lines.gml
type: vector

- algorithm: qgis:meancoordinates
name: standard mean coordinates
params:
POINTS:
name: custom/points.shp
type: vector
results:
OUTPUT:
name: expected/mean_coordinates.gml
type: vector

0 comments on commit 7958db2

Please sign in to comment.