]> granicus.if.org Git - postgis/commitdiff
Add regression test for trigonometric length calculation
authorPaul Ramsey <pramsey@cleverelephant.ca>
Mon, 18 Sep 2017 13:21:53 +0000 (13:21 +0000)
committerPaul Ramsey <pramsey@cleverelephant.ca>
Mon, 18 Sep 2017 13:21:53 +0000 (13:21 +0000)
for compoundcurve (references #3774)

git-svn-id: http://svn.osgeo.org/postgis/trunk@15755 b70326c6-7e19-0410-871a-916f4a2858ee

regress/tickets.sql
regress/tickets_expected

index d774c4e7185f4b174e99e4f0ae109fe792240812..c5745e8822accd90e586570b5220672a6c0fe793 100644 (file)
@@ -1022,5 +1022,8 @@ SELECT '#3704', ST_AsX3D('LINESTRING EMPTY') = '';
 -- #3709
 select '#3709', ST_SnapToGrid(ST_Project('SRID=4326;POINT(1 1)'::geography, 100000, 20)::geometry, 0.0001) = ST_SnapToGrid(ST_Project('SRID=4326;POINT(1 1)'::geography, -100000, 20+pi())::geometry, 0.0001);
 
+-- #3774
+select '#3774', abs(pi() + 2 - st_length('COMPOUNDCURVE(CIRCULARSTRING(0 0, 1 1, 2 0), (2 0, 4 0))'::geometry)) < 0.000000001;
+
 -- Clean up
 DELETE FROM spatial_ref_sys;
index 86b62a6642c1d452e74df563cd9e61bf9155b1c7..7ae44fc6285b279007188019c793a9297d625ad1 100644 (file)
@@ -305,3 +305,4 @@ ERROR:  invalid KML representation
 #3627b|t
 #3704|t
 #3709|t
+#3774|t