Skip to content

Commit 7958db2

Browse files
ghtmttm-kuhn
authored andcommitted
processing mean coordinates test
1 parent 2c66493 commit 7958db2

File tree

3 files changed

+65
-0
lines changed

3 files changed

+65
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<GMLFeatureClassList>
2+
<GMLFeatureClass>
3+
<Name>mean_coordinates</Name>
4+
<ElementPath>mean_coordinates</ElementPath>
5+
<!--POINT-->
6+
<GeometryType>1</GeometryType>
7+
<SRSName>EPSG:4326</SRSName>
8+
<DatasetSpecificInfo>
9+
<FeatureCount>1</FeatureCount>
10+
<ExtentXMin>3.33333</ExtentXMin>
11+
<ExtentXMax>3.33333</ExtentXMax>
12+
<ExtentYMin>0.11111</ExtentYMin>
13+
<ExtentYMax>0.11111</ExtentYMax>
14+
</DatasetSpecificInfo>
15+
<PropertyDefn>
16+
<Name>MEAN_X</Name>
17+
<ElementPath>MEAN_X</ElementPath>
18+
<Type>Real</Type>
19+
</PropertyDefn>
20+
<PropertyDefn>
21+
<Name>MEAN_Y</Name>
22+
<ElementPath>MEAN_Y</ElementPath>
23+
<Type>Real</Type>
24+
</PropertyDefn>
25+
<PropertyDefn>
26+
<Name>UID</Name>
27+
<ElementPath>UID</ElementPath>
28+
<Type>String</Type>
29+
<Width>12</Width>
30+
</PropertyDefn>
31+
</GMLFeatureClass>
32+
</GMLFeatureClassList>
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<ogr:FeatureCollection
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xsi:schemaLocation=""
5+
xmlns:ogr="http://ogr.maptools.org/"
6+
xmlns:gml="http://www.opengis.net/gml">
7+
<gml:boundedBy>
8+
<gml:Box>
9+
<gml:coord><gml:X>3.333333333333333</gml:X><gml:Y>0.1111111111111111</gml:Y></gml:coord>
10+
<gml:coord><gml:X>3.333333333333333</gml:X><gml:Y>0.1111111111111111</gml:Y></gml:coord>
11+
</gml:Box>
12+
</gml:boundedBy>
13+
14+
<gml:featureMember>
15+
<ogr:mean_coordinates fid="mean_coordinates.0">
16+
<ogr:geometryProperty><gml:Point srsName="EPSG:4326"><gml:coordinates>3.33333333333333,0.111111111111111</gml:coordinates></gml:Point></ogr:geometryProperty>
17+
<ogr:MEAN_X>3.333333333333333</ogr:MEAN_X>
18+
<ogr:MEAN_Y>0.111111111111111</ogr:MEAN_Y>
19+
<ogr:UID>Single class</ogr:UID>
20+
</ogr:mean_coordinates>
21+
</gml:featureMember>
22+
</ogr:FeatureCollection>

python/plugins/processing/tests/testdata/qgis_algorithm_tests.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2191,3 +2191,14 @@ tests:
21912191
OUTPUT:
21922192
name: expected/points_alog_lines.gml
21932193
type: vector
2194+
2195+
- algorithm: qgis:meancoordinates
2196+
name: standard mean coordinates
2197+
params:
2198+
POINTS:
2199+
name: custom/points.shp
2200+
type: vector
2201+
results:
2202+
OUTPUT:
2203+
name: expected/mean_coordinates.gml
2204+
type: vector

0 commit comments

Comments
 (0)