]> granicus.if.org Git - postgis/commitdiff
Test invalid calls to topogeo_addpoint
authorSandro Santilli <strk@keybit.net>
Tue, 3 Jan 2012 20:24:29 +0000 (20:24 +0000)
committerSandro Santilli <strk@keybit.net>
Tue, 3 Jan 2012 20:24:29 +0000 (20:24 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@8657 b70326c6-7e19-0410-871a-916f4a2858ee

topology/test/regress/topogeo_addpoint.sql
topology/test/regress/topogeo_addpoint_expected

index 4399dfe86be5c81f85502d6de0fea1e022eca2ca..5a93771361010752d8da6179fd8e68758c9195fd 100644 (file)
@@ -3,6 +3,10 @@ set client_min_messages to ERROR;
 
 \i load_topology.sql
 
+-- Invalid calls
+SELECT 'invalid', TopoGeo_addPoint('city_data', 'LINESTRING(36 26, 38 30)');
+SELECT 'invalid', TopoGeo_addPoint('city_data', 'MULTIPOINT((36 26))');
+
 -- Save max node id
 select 'node'::text as what, max(node_id) INTO city_data.limits FROM city_data.node;
 
index dde51d11117c1b0b48fad55f00fbfd53371fe0ae..026d2dbfaddc01a4d464da6d73e2968b16a5db27 100644 (file)
@@ -4,6 +4,8 @@ t
 22
 26
 COMMIT
+ERROR:  Invalid geometry type (LINESTRING) passed to TopoGeo_AddPoint, expected POINT
+ERROR:  Invalid geometry type (MULTIPOINT) passed to TopoGeo_AddPoint, expected POINT
 iso_uni|23
 iso_f3|24
 iso_ex|23