[SCM] PostGIS branch master updated. 3.6.0rc2-470-g0feee1927
git at osgeo.org
git at osgeo.org
Fri Apr 17 00:54:49 PDT 2026
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "PostGIS".
The branch, master has been updated
via 0feee19278e423922717b788dd14cc9823cadc0e (commit)
from bb1a71e15fdece2cab099682be270683b529cbc9 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 0feee19278e423922717b788dd14cc9823cadc0e
Author: Sandro Santilli <strk at kbt.io>
Date: Fri Apr 17 09:54:30 2026 +0200
Put ST_Azimuth tests in its own file
diff --git a/regress/core/azimuth.sql b/regress/core/azimuth.sql
new file mode 100644
index 000000000..2e2977413
--- /dev/null
+++ b/regress/core/azimuth.sql
@@ -0,0 +1,57 @@
+--- ST_Azimuth
+SELECT 'ST_Azimuth_regular' , round(ST_Azimuth(geom1,geom2)::numeric,4)
+FROM CAST('POINT(0 1)' AS geometry) AS geom1, CAST('POINT(1 0)' AS geometry) AS geom2 ;
+SELECT 'ST_Azimuth_same_point' , ST_Azimuth(geom1,geom1)
+FROM CAST('POINT(0 1)' AS geometry) AS geom1 ;
+SELECT 'ST_Azimuth_mixed_srid' , ST_Azimuth(geom1,geom2)
+FROM CAST('POINT(0 1)' AS geometry) AS geom1, ST_GeomFromText('POINT(1 0)',4326) AS geom2;
+SELECT 'ST_Azimuth_not_point' , ST_Azimuth(geom1,geom2)
+FROM CAST('POINT(0 1)' AS geometry) AS geom1, ST_GeomFromText('LINESTRING(1 0 ,2 0)',4326) AS geom2;
+SELECT 'ST_Azimuth_null_geom' , ST_Azimuth(geom1,geom2)
+FROM CAST('POINT(0 1)' AS geometry) AS geom1, ST_GeomFromText('EMPTY') AS geom2;
+
+
+-- #1305
+SELECT '#1305.1',ST_AsText(ST_Project('POINT(10 10)'::geography, 0, 0));
+WITH pts AS ( SELECT 'POINT(0 45)'::geography AS s, 'POINT(45 45)'::geography AS e )
+SELECT '#1305.2',abs(ST_Distance(e, ST_Project(s, ST_Distance(s, e), ST_Azimuth(s, e)))) < 0.001 FROM pts;
+SELECT '#1305.3',ST_Azimuth('POINT(0 45)'::geography, 'POINT(0 45)'::geography) IS NULL;
+
+
+-- #1791 --
+with inp as ( SELECT
+ '010100000000000000004065C0041AD965BE5554C0'::geometry as a,
+ '010100000001000000004065C0041AD965BE5554C0'::geometry as b
+) SELECT '#1791', round(ST_Azimuth(a,b)*10)/10 from inp;
+
+SELECT '#4718',
+ round(degrees(
+ ST_Azimuth('POINT(77.46412 37.96999)'::geography,
+ 'POINT(77.46409 37.96999)'::geography
+ ))::numeric,3),
+ round(degrees(
+ ST_Azimuth('POINT(77.46412 37.96999)'::geography,
+ 'POINT(77.46429 37.96999)'::geography
+ ))::numeric,3);
+
+SELECT
+'#4840',
+round(degrees(ST_azimuth(C,N))) AS az_n,
+round(degrees(ST_azimuth(C,NE))) AS az_ne,
+round(degrees(ST_azimuth(C,E))) AS az_e,
+round(degrees(ST_azimuth(C,SE))) AS az_se,
+round(degrees(ST_azimuth(C,S))) AS az_s,
+round(degrees(ST_azimuth(C,SW))) AS az_sw,
+round(degrees(ST_azimuth(C,W))) AS az_w,
+round(degrees(ST_azimuth(C,NW))) AS az_nw
+FROM (SELECT
+'POINT(5 55)'::geography AS C,
+'POINT(5 56)'::geography AS N,
+'POINT(6 56)'::geography AS NE,
+'POINT(6 55)'::geography AS E,
+'POINT(6 54)'::geography AS SE,
+'POINT(5 54)'::geography AS S,
+'POINT(4 54)'::geography AS SW,
+'POINT(4 55)'::geography AS W,
+'POINT(4 56)'::geography AS NW ) points;
+
diff --git a/regress/core/azimuth_expected b/regress/core/azimuth_expected
new file mode 100644
index 000000000..c24002591
--- /dev/null
+++ b/regress/core/azimuth_expected
@@ -0,0 +1,11 @@
+ST_Azimuth_regular|2.3562
+ST_Azimuth_same_point|
+ERROR: Operation on mixed SRID geometries
+ERROR: Argument must be POINT geometries
+ERROR: parse error - invalid geometry
+#1305.1|POINT(10 10)
+#1305.2|t
+#1305.3|t
+#1791|4.7
+#4718|270.000|90.000
+#4840|0|29|90|149|180|211|270|331
diff --git a/regress/core/lwgeom_regress.sql b/regress/core/lwgeom_regress.sql
index c31487c30..3c647e3c8 100644
--- a/regress/core/lwgeom_regress.sql
+++ b/regress/core/lwgeom_regress.sql
@@ -155,18 +155,6 @@ SELECT 'BoundingDiagonal7.1', ST_AsEwkt(ST_BoundingDiagonal(postgis_addbbox('SRI
SELECT 'BoundingDiagonal7.2', ST_AsEwkt(ST_BoundingDiagonal('SRID=3857;MULTILINESTRING Z ((5 4 0,4 4 1))'::geometry));
SELECT 'BoundingDiagonal7.3', ST_AsEwkt(ST_BoundingDiagonal(postgis_addbbox('SRID=3857;MULTILINESTRING Z ((5 4 0,4 4 1))'::geometry)));
---- ST_Azimuth
-SELECT 'ST_Azimuth_regular' , round(ST_Azimuth(geom1,geom2)::numeric,4)
-FROM CAST('POINT(0 1)' AS geometry) AS geom1, CAST('POINT(1 0)' AS geometry) AS geom2 ;
-SELECT 'ST_Azimuth_same_point' , ST_Azimuth(geom1,geom1)
-FROM CAST('POINT(0 1)' AS geometry) AS geom1 ;
-SELECT 'ST_Azimuth_mixed_srid' , ST_Azimuth(geom1,geom2)
-FROM CAST('POINT(0 1)' AS geometry) AS geom1, ST_GeomFromText('POINT(1 0)',4326) AS geom2;
-SELECT 'ST_Azimuth_not_point' , ST_Azimuth(geom1,geom2)
-FROM CAST('POINT(0 1)' AS geometry) AS geom1, ST_GeomFromText('LINESTRING(1 0 ,2 0)',4326) AS geom2;
-SELECT 'ST_Azimuth_null_geom' , ST_Azimuth(geom1,geom2)
-FROM CAST('POINT(0 1)' AS geometry) AS geom1, ST_GeomFromText('EMPTY') AS geom2;
-
--- ST_Angle(points)
SELECT 'ST_Angle_4_pts', St_Angle(p1,p2,p3,p4)::numeric(12,6)
FROM ST_GeomFromtext('POINT(0 1)') AS p1, ST_GeomFromtext('POINT(0 0)') AS p2
diff --git a/regress/core/lwgeom_regress_expected b/regress/core/lwgeom_regress_expected
index dc3a70ecc..8239d0fec 100644
--- a/regress/core/lwgeom_regress_expected
+++ b/regress/core/lwgeom_regress_expected
@@ -42,11 +42,6 @@ BoundingDiagonal7 |SRID=3857;LINESTRINGM(4 4 0,5 4 1)
BoundingDiagonal7.1|SRID=3857;LINESTRINGM(4 4 0,5 4 1)
BoundingDiagonal7.2|SRID=3857;LINESTRING(4 4 0,5 4 1)
BoundingDiagonal7.3|SRID=3857;LINESTRING(4 4 0,5 4 1)
-ST_Azimuth_regular|2.3562
-ST_Azimuth_same_point|
-ERROR: Operation on mixed SRID geometries
-ERROR: Argument must be POINT geometries
-ERROR: parse error - invalid geometry
ST_Angle_4_pts|4.712389
ST_Angle_4_pts|0.785398
ST_Angle_3_pts|1.570796
diff --git a/regress/core/tests.mk.in b/regress/core/tests.mk.in
index fc998a755..5e334ee5e 100644
--- a/regress/core/tests.mk.in
+++ b/regress/core/tests.mk.in
@@ -29,6 +29,7 @@ RUNTESTFLAGS_INTERNAL += \
TESTS += \
$(top_srcdir)/regress/core/affine \
+ $(top_srcdir)/regress/core/azimuth \
$(top_srcdir)/regress/core/bestsrid \
$(top_srcdir)/regress/core/binary \
$(top_srcdir)/regress/core/boundary \
diff --git a/regress/core/tickets.sql b/regress/core/tickets.sql
index 4c1fcb862..1dd8f2e98 100644
--- a/regress/core/tickets.sql
+++ b/regress/core/tickets.sql
@@ -489,12 +489,6 @@ SELECT '#657.1',Round(ST_X(ST_Project('POINT(175 10)'::geography, 2000000, 3.141
SELECT '#657.2',Round(ST_Distance(ST_Project('POINT(10 10)'::geography, 10, 0), 'POINT(10 10)'::geography)::numeric,2);
SELECT '#657.3',ST_DWithin(ST_Project('POINT(10 10)'::geography, 2000, pi()/2), 'POINT(10 10)'::geography, 2000);
--- #1305
-SELECT '#1305.1',ST_AsText(ST_Project('POINT(10 10)'::geography, 0, 0));
-WITH pts AS ( SELECT 'POINT(0 45)'::geography AS s, 'POINT(45 45)'::geography AS e )
-SELECT '#1305.2',abs(ST_Distance(e, ST_Project(s, ST_Distance(s, e), ST_Azimuth(s, e)))) < 0.001 FROM pts;
-SELECT '#1305.3',ST_Azimuth('POINT(0 45)'::geography, 'POINT(0 45)'::geography) IS NULL;
-
-- #1445
SELECT '01060000400200000001040000400100000001010000400000000000000000000000000000000000000000000000000101000040000000000000F03F000000000000F03F000000000000F03F'::geometry;
SELECT '01050000400200000001040000400100000001010000400000000000000000000000000000000000000000000000000101000040000000000000F03F000000000000F03F000000000000F03F'::geometry;
@@ -679,12 +673,6 @@ FROM inp;
-- #1780 --
SELECT '#1780',ST_GeoHash('POINT(4 4)'::geometry) = ST_GeoHash('POINT(4 4)'::geography);
--- #1791 --
-with inp as ( SELECT
- '010100000000000000004065C0041AD965BE5554C0'::geometry as a,
- '010100000001000000004065C0041AD965BE5554C0'::geometry as b
-) SELECT '#1791', round(ST_Azimuth(a,b)*10)/10 from inp;
-
-- #1799 --
SELECT '#1799', ST_Segmentize('LINESTRING(0 0, 10 0)'::geometry, 0);
@@ -1343,16 +1331,6 @@ SELECT '#4689', _ST_DistanceTree('POLYGON ((30 10, 40 40, 20 40, 30 10))'::geogr
SELECT '#4748', ST_AsEWKT(ST_Transform(ST_SetSRID(ST_Point(-36.75, -54.25), 4326), 3031),1);
SELECT '#4842', ST_AsEWKT(ST_Transform(ST_SetSRID(ST_Point(12.572, 66.081), 4326), 3413),1);
-SELECT '#4718',
- round(degrees(
- ST_Azimuth('POINT(77.46412 37.96999)'::geography,
- 'POINT(77.46409 37.96999)'::geography
- ))::numeric,3),
- round(degrees(
- ST_Azimuth('POINT(77.46412 37.96999)'::geography,
- 'POINT(77.46429 37.96999)'::geography
- ))::numeric,3);
-
SELECT '#4727', _ST_DistanceTree('SRID=4326;POLYGON((-179.9 -85.05112877980659, -179.9 74.99999999999997, -152 80, -130 84.99999999999997, -115 85.05112877980659, -60 85.05112877980659, -60 79, -70 70, -130 50, -80 6, -65 -53, -100 -85.05112877980659, -179.9 -85.05112877980659))'::geography,
ST_MakePoint(-150,-40), 0.0, true);
@@ -1360,27 +1338,6 @@ SELECT '#4796', st_astext(st_snaptogrid(st_normalize(st_simplifypreservetopology
SELECT '#4812', st_srid('SRID=999999;POINT(1 1)'::geometry);
-SELECT
-'#4840',
-round(degrees(ST_azimuth(C,N))) AS az_n,
-round(degrees(ST_azimuth(C,NE))) AS az_ne,
-round(degrees(ST_azimuth(C,E))) AS az_e,
-round(degrees(ST_azimuth(C,SE))) AS az_se,
-round(degrees(ST_azimuth(C,S))) AS az_s,
-round(degrees(ST_azimuth(C,SW))) AS az_sw,
-round(degrees(ST_azimuth(C,W))) AS az_w,
-round(degrees(ST_azimuth(C,NW))) AS az_nw
-FROM (SELECT
-'POINT(5 55)'::geography AS C,
-'POINT(5 56)'::geography AS N,
-'POINT(6 56)'::geography AS NE,
-'POINT(6 55)'::geography AS E,
-'POINT(6 54)'::geography AS SE,
-'POINT(5 54)'::geography AS S,
-'POINT(4 54)'::geography AS SW,
-'POINT(4 55)'::geography AS W,
-'POINT(4 56)'::geography AS NW ) points;
-
SELECT '#4853', ST_ClusterDBSCAN(geom, eps := 0.000906495804256269, minpoints := 4) OVER() AS cid FROM (VALUES ('0101000020E6100000E4141DC9E5934B40D235936FB6193940'::geometry), ('0101000020E6100000C746205ED7934B40191C25AFCE193940'::geometry), ('0101000020E6100000C780ECF5EE934B40B6BE4868CB193940'::geometry), ('0101000020E6100000ABB2EF8AE0934B404451A04FE4193940'::geometry)) AS t(geom);
SELECT '#4844', ST_AsEWKT(ST_SnapToGrid(ST_Transform('SRID=3575;POINT(370182.35945313 -2213980.8213281)'::geometry,4326),0.001));
diff --git a/regress/core/tickets_expected b/regress/core/tickets_expected
index b8b5e345c..c6185f24e 100644
--- a/regress/core/tickets_expected
+++ b/regress/core/tickets_expected
@@ -167,9 +167,6 @@ NOTICE: Coordinate values were coerced into range [-180 -90, 180 90] for GEOGRA
#657.1|-166.78
#657.2|10.00
#657.3|t
-#1305.1|POINT(10 10)
-#1305.2|t
-#1305.3|t
ERROR: MultiPolygon cannot contain MultiPoint element at character 8
ERROR: MultiLineString cannot contain MultiPoint element at character 8
ERROR: MultiPoint cannot contain MultiPoint element at character 8
@@ -218,7 +215,6 @@ NOTICE: SRID value -1 converted to the officially unknown SRID value 0
#1755|01e9030000000000000040554000000000008041400000000000000000
#1776|POLYGON((0 0,10 0,10 10,0 0))|POLYGON((0 0,10 0,10 10,0 0))
#1780|t
-#1791|4.7
ERROR: ST_Segmentize: invalid max_distance 0 (must be >= 0)
ERROR: invalid GML representation
#1957|1
@@ -439,11 +435,9 @@ ERROR: LWGEOM_addpoint: Invalid offset
#4689|0
#4748|SRID=3031;POINT(-2399498.7 3213318.5)
#4842|SRID=3413;POINT(2218086.2 -1409161.3)
-#4718|270.000|90.000
#4727|0
#4796|POLYGON((178632 397744,178738 397769,178745 397741,178749 397742,178752 397727,178748 397726,178759 397684,178699 397669,178694 397691,178646 397680,178632 397744))
#4812|999999
-#4840|0|29|90|149|180|211|270|331
#4853|0
#4853|0
#4853|0
-----------------------------------------------------------------------
Summary of changes:
regress/core/azimuth.sql | 57 ++++++++++++++++++++++++++++++++++++
regress/core/azimuth_expected | 11 +++++++
regress/core/lwgeom_regress.sql | 12 --------
regress/core/lwgeom_regress_expected | 5 ----
regress/core/tests.mk.in | 1 +
regress/core/tickets.sql | 43 ---------------------------
regress/core/tickets_expected | 6 ----
7 files changed, 69 insertions(+), 66 deletions(-)
create mode 100644 regress/core/azimuth.sql
create mode 100644 regress/core/azimuth_expected
hooks/post-receive
--
PostGIS
More information about the postgis-tickets
mailing list