[postgis-tickets] r15755 - Add regression test for trigonometric length calculation

Paul Ramsey pramsey at cleverelephant.ca
Mon Sep 18 06:21:53 PDT 2017


Author: pramsey
Date: 2017-09-18 06:21:53 -0700 (Mon, 18 Sep 2017)
New Revision: 15755

Modified:
   trunk/regress/tickets.sql
   trunk/regress/tickets_expected
Log:
Add regression test for trigonometric length calculation
for compoundcurve (references #3774)


Modified: trunk/regress/tickets.sql
===================================================================
--- trunk/regress/tickets.sql	2017-09-18 12:30:30 UTC (rev 15754)
+++ trunk/regress/tickets.sql	2017-09-18 13:21:53 UTC (rev 15755)
@@ -1022,5 +1022,8 @@
 -- #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;

Modified: trunk/regress/tickets_expected
===================================================================
--- trunk/regress/tickets_expected	2017-09-18 12:30:30 UTC (rev 15754)
+++ trunk/regress/tickets_expected	2017-09-18 13:21:53 UTC (rev 15755)
@@ -305,3 +305,4 @@
 #3627b|t
 #3704|t
 #3709|t
+#3774|t



More information about the postgis-tickets mailing list