[postgis-tickets] [SCM] PostGIS branch master updated. 3.1.0alpha2-115-g402fdc0
git at osgeo.org
git at osgeo.org
Thu Oct 29 07:34:47 PDT 2020
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 402fdc0e8191422b23996eafde93b2dce33c1595 (commit)
from 72e4e9de69b44c56f8bff8515dcdb9f3511f009a (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 402fdc0e8191422b23996eafde93b2dce33c1595
Author: Sandro Santilli <strk at kbt.io>
Date: Thu Oct 29 14:23:55 2020 +0100
Run all regress tests in the same database
Speeds up regression testing and catches some issues in presence
of multiple components in the same db.
Still allows running individual testsuites from within their
respective directory.
diff --git a/GNUmakefile.in b/GNUmakefile.in
index 3daf08b..2fe6a9b 100644
--- a/GNUmakefile.in
+++ b/GNUmakefile.in
@@ -9,6 +9,8 @@ ifeq (@LIBLWGEOM_ONLY@,no)
SUBDIRS += libpgcommon postgis regress @RASTER@ @TOPOLOGY@ @SFCGAL@ loader utils doc @EXTENSIONS@ @DEPS_SUBDIR@
endif
+HAVE_SFCGAL=@HAVE_SFCGAL@
+
POSTGIS_MAJOR_VERSION=@POSTGIS_MAJOR_VERSION@
POSTGIS_MINOR_VERSION=@POSTGIS_MINOR_VERSION@
POSTGIS_MICRO_VERSION=@POSTGIS_MICRO_VERSION@
@@ -16,7 +18,7 @@ POSTGIS_MICRO_VERSION=@POSTGIS_MICRO_VERSION@
PERL = @PERL@
# todo: add more rules here, like uninstall, clean...
-all install uninstall noop clean distclean check-unit check-regress:
+all install uninstall noop clean distclean check-unit:
for s in $(SUBDIRS); do \
echo "---- Making $@ in $${s}"; \
$(MAKE) -C $${s} $@ || exit 1; \
@@ -185,3 +187,30 @@ postgis_revision.h:
$(PERL) utils/repo_revision.pl
.PHONY: utils liblwgeom ChangeLog raster
+
+topsrcdir = $(realpath ./)
+include regress/core/tests.mk
+include regress/loader/tests.mk
+include regress/dumper/tests.mk
+ifeq ($(HAVE_SFCGAL),yes)
+ override RUNTESTFLAGS := $(RUNTESTFLAGS) --sfcgal
+ include regress/sfcgal/tests.mk
+endif
+ifeq (@TOPOLOGY@,topology)
+ override RUNTESTFLAGS := $(RUNTESTFLAGS) --topology
+ include topology/test/tests.mk
+endif
+ifeq (@RASTER@,raster)
+ override RUNTESTFLAGS := $(RUNTESTFLAGS) --raster
+ include raster/test/regress/tests.mk
+endif
+
+include regress/runtest.mk
+
+check-regress: staged-install check-regress-deps
+
+check-regress-deps:
+ifeq (@TOPOLOGY@,topology)
+ $(MAKE) -C topology/test $@
+endif
+
diff --git a/raster/test/regress/Makefile.in b/raster/test/regress/Makefile.in
index d77a6d6..5c0ea48 100644
--- a/raster/test/regress/Makefile.in
+++ b/raster/test/regress/Makefile.in
@@ -184,7 +184,7 @@ override RUNTESTFLAGS := $(RUNTESTFLAGS) --raster
topsrcdir = $(realpath ../../../)
-#include tests.mk
-TESTS += $(patsubst %, $(topsrcdir)/raster/test/regress/%, $(RASTER_TESTS))
+include tests.mk
include ../../../regress/runtest.mk
+check: check-regress
diff --git a/raster/test/regress/tests.mk b/raster/test/regress/tests.mk
new file mode 100644
index 0000000..39fb529
--- /dev/null
+++ b/raster/test/regress/tests.mk
@@ -0,0 +1,138 @@
+# **********************************************************************
+# *
+# * PostGIS - Spatial Types for PostgreSQL
+# * http://postgis.net
+# *
+# * Copyright (C) 2020 Sandro Santilli <strk at kbt.io>
+# *
+# * This is free software; you can redistribute and/or modify it under
+# * the terms of the GNU General Public Licence. See the COPYING file.
+# *
+# **********************************************************************
+
+RASTER_TEST_FIRST = \
+ check_gdal \
+ load_outdb
+
+RASTER_TEST_LAST = \
+ clean
+
+RASTER_TEST_METADATA = \
+ check_raster_columns \
+ check_raster_overviews
+
+RASTER_TEST_IO = \
+ rt_io
+
+RASTER_TEST_BASIC_FUNC = \
+ rt_bytea \
+ rt_wkb \
+ box3d \
+ rt_addband \
+ rt_band \
+ rt_tile
+
+RASTER_TEST_PROPS = \
+ rt_dimensions \
+ rt_scale \
+ rt_pixelsize \
+ rt_upperleft \
+ rt_rotation \
+ rt_georeference \
+ rt_set_properties \
+ rt_isempty \
+ rt_hasnoband \
+ rt_metadata \
+ rt_rastertoworldcoord \
+ rt_worldtorastercoord \
+ rt_convexhull \
+ rt_envelope
+
+RASTER_TEST_BANDPROPS = \
+ rt_band_properties \
+ rt_set_band_properties \
+ rt_pixelaspolygons \
+ rt_pixelaspoints \
+ rt_pixelascentroids \
+ rt_setvalues_array \
+ rt_summarystats \
+ rt_count \
+ rt_histogram \
+ rt_quantile \
+ rt_valuecount \
+ rt_valuepercent \
+ rt_bandmetadata \
+ rt_pixelvalue \
+ rt_neighborhood \
+ rt_nearestvalue \
+ rt_pixelofvalue \
+ rt_polygon \
+ rt_setbandpath
+
+RASTER_TEST_UTILITY = \
+ rt_utility \
+ rt_fromgdalraster \
+ rt_asgdalraster \
+ rt_astiff \
+ rt_asjpeg \
+ rt_aspng \
+ rt_reclass \
+ rt_gdalwarp \
+ rt_asraster \
+ rt_dumpvalues \
+ rt_makeemptycoverage \
+ rt_createoverview
+
+RASTER_TEST_MAPALGEBRA = \
+ rt_mapalgebraexpr \
+ rt_mapalgebrafct \
+ rt_mapalgebraexpr_2raster \
+ rt_mapalgebrafct_2raster \
+ rt_mapalgebrafctngb \
+ rt_mapalgebrafctngb_userfunc \
+ rt_intersection \
+ rt_clip \
+ rt_mapalgebra \
+ rt_mapalgebra_expr \
+ rt_mapalgebra_mask \
+ rt_union \
+ rt_invdistweight4ma \
+ rt_4ma \
+ rt_setvalues_geomval \
+ rt_elevation_functions \
+ rt_colormap \
+ rt_grayscale
+
+RASTER_TEST_SREL = \
+ rt_gist_relationships \
+ rt_intersects \
+ rt_samealignment \
+ rt_geos_relationships \
+ rt_iscoveragetile
+
+RASTER_TEST_BUGS = \
+ bug_test_car5 \
+ permitted_gdal_drivers \
+ tickets
+
+RASTER_TEST_LOADER = \
+ loader/Basic \
+ loader/Projected \
+ loader/BasicCopy \
+ loader/BasicFilename \
+ loader/BasicOutDB \
+ loader/Tiled10x10 \
+ loader/Tiled10x10Copy \
+ loader/Tiled8x8 \
+ loader/TiledAuto \
+ loader/TiledAutoSkipNoData
+
+RASTER_TESTS := $(RASTER_TEST_FIRST) \
+ $(RASTER_TEST_METADATA) $(RASTER_TEST_IO) $(RASTER_TEST_BASIC_FUNC) \
+ $(RASTER_TEST_PROPS) $(RASTER_TEST_BANDPROPS) \
+ $(RASTER_TEST_UTILITY) $(RASTER_TEST_MAPALGEBRA) $(RASTER_TEST_SREL) \
+ $(RASTER_TEST_BUGS) \
+ $(RASTER_TEST_LOADER) \
+ $(RASTER_TEST_LAST)
+
+TESTS += $(patsubst %, $(topsrcdir)/raster/test/regress/%, $(RASTER_TESTS))
diff --git a/regress/Makefile.in b/regress/Makefile.in
index 66d53df..4b50948 100644
--- a/regress/Makefile.in
+++ b/regress/Makefile.in
@@ -42,7 +42,7 @@ export PATH
all install uninstall:
check-regress: staged-install
-check-regress: check
+check: check-regress
check-unit:
diff --git a/regress/core/Makefile.in b/regress/core/Makefile.in
index 5d24128..b6f4013 100644
--- a/regress/core/Makefile.in
+++ b/regress/core/Makefile.in
@@ -16,3 +16,5 @@ topsrcdir = $(realpath ../../)
include tests.mk
include ../runtest.mk
+
+check: check-regress
diff --git a/regress/core/simplify.sql b/regress/core/simplify.sql
index d5c2b01..34b52db 100644
--- a/regress/core/simplify.sql
+++ b/regress/core/simplify.sql
@@ -1,28 +1,28 @@
-- Repeat all tests with the new function names.
-SELECT '1', ST_astext(ST_Simplify('LINESTRING(0 0, 0 10, 0 51, 50 20, 30 20, 7 32)', 2));
-SELECT '2', ST_astext(ST_Simplify('LINESTRING(0 0 3, 0 10 6, 0 51 1, 50 20 6, 30 20 9, 7 32 10)', 2));
-SELECT '3', ST_astext(ST_Simplify('LINESTRINGM(0 0 3, 0 10 6, 0 51 1, 50 20 6, 30 20 9, 7 32 10)', 2));
-SELECT '4', ST_astext(ST_Simplify('LINESTRING(0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5)', 2));
-SELECT '5', ST_astext(ST_Simplify('MULTIPOINT(0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5)', 20));
-SELECT '6', ST_astext(ST_Simplify('MULTILINESTRING((0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5), (0 0 4 3, 1 1 2 3, 20 20 5 30))', 20));
-SELECT '7', ST_astext(ST_Simplify('POLYGON((0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5, 0 0 3 2), (1 1 4 3, 1 3 2 3, 18 18 5 30, 1 1 4 3))', 20));
-SELECT '8', ST_astext(ST_Simplify('POLYGON((0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5, 0 0 3 2), (1 1 4 3, 1 3 2 3, 18 18 5 30, 1 1 4 3))', 1));
+SELECT '1', ST_astext(ST_Simplify('LINESTRING(0 0, 0 10, 0 51, 50 20, 30 20, 7 32)'::geometry, 2));
+SELECT '2', ST_astext(ST_Simplify('LINESTRING(0 0 3, 0 10 6, 0 51 1, 50 20 6, 30 20 9, 7 32 10)'::geometry, 2));
+SELECT '3', ST_astext(ST_Simplify('LINESTRINGM(0 0 3, 0 10 6, 0 51 1, 50 20 6, 30 20 9, 7 32 10)'::geometry, 2));
+SELECT '4', ST_astext(ST_Simplify('LINESTRING(0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5)'::geometry, 2));
+SELECT '5', ST_astext(ST_Simplify('MULTIPOINT(0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5)'::geometry, 20));
+SELECT '6', ST_astext(ST_Simplify('MULTILINESTRING((0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5), (0 0 4 3, 1 1 2 3, 20 20 5 30))'::geometry, 20));
+SELECT '7', ST_astext(ST_Simplify('POLYGON((0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5, 0 0 3 2), (1 1 4 3, 1 3 2 3, 18 18 5 30, 1 1 4 3))'::geometry, 20));
+SELECT '8', ST_astext(ST_Simplify('POLYGON((0 0 3 2, 0 10 6 1, 0 51 1 6, 50 20 6 7, 30 20 9 9, 7 32 10 5, 0 0 3 2), (1 1 4 3, 1 3 2 3, 18 18 5 30, 1 1 4 3))'::geometry, 1));
-SELECT '9', ST_astext(ST_Simplify('POLYGON((0 0, 10 0, 10 10, 0 10, 0 0),(5 5, 5 6, 6 6, 8 5, 5 5))', 20));
-SELECT '10', ST_astext(ST_Simplify('LINESTRING(0 0, 0 10)', 20));
-SELECT '11', ST_astext(ST_Simplify('MULTIPOLYGON(((100 100, 100 130, 130 130, 130 100, 100 100)), ((0 0, 10 0, 10 10, 0 10, 0 0),(5 5, 5 6, 6 6, 8 5, 5 5)) )', 20));
-SELECT '12', ST_astext(ST_Simplify('MULTIPOLYGON(((0 0, 10 0, 10 10, 0 10, 0 0),(5 5, 5 6, 6 6, 8 5, 5 5)),((100 100, 100 130, 130 130, 130 100, 100 100)))', 20));
+SELECT '9', ST_astext(ST_Simplify('POLYGON((0 0, 10 0, 10 10, 0 10, 0 0),(5 5, 5 6, 6 6, 8 5, 5 5))'::geometry, 20));
+SELECT '10', ST_astext(ST_Simplify('LINESTRING(0 0, 0 10)'::geometry, 20));
+SELECT '11', ST_astext(ST_Simplify('MULTIPOLYGON(((100 100, 100 130, 130 130, 130 100, 100 100)), ((0 0, 10 0, 10 10, 0 10, 0 0),(5 5, 5 6, 6 6, 8 5, 5 5)) )'::geometry, 20));
+SELECT '12', ST_astext(ST_Simplify('MULTIPOLYGON(((0 0, 10 0, 10 10, 0 10, 0 0),(5 5, 5 6, 6 6, 8 5, 5 5)),((100 100, 100 130, 130 130, 130 100, 100 100)))'::geometry, 20));
-SELECT '13', ST_astext(ST_Simplify('POLYGON((0 0, 10 0, 10 10, 0 10, 0 0))', 20, false));
-SELECT '14', ST_astext(ST_Simplify('POLYGON((0 0, 10 0, 10 10, 0 10, 0 0))', 20, true));
+SELECT '13', ST_astext(ST_Simplify('POLYGON((0 0, 10 0, 10 10, 0 10, 0 0))'::geometry, 20, false));
+SELECT '14', ST_astext(ST_Simplify('POLYGON((0 0, 10 0, 10 10, 0 10, 0 0))'::geometry, 20, true));
-- Updates the geometry bbox
WITH geom AS
(
- SELECT ST_Simplify('POLYGON((0 0, 10 0, 10 10, 10.6 10, 10.5 10.5, 10 10, 0 10, 0 0))', 1) as g
+ SELECT ST_Simplify('POLYGON((0 0, 10 0, 10 10, 10.6 10, 10.5 10.5, 10 10, 0 10, 0 0))'::geometry, 1) as g
)
Select '15', ST_AsText(g) as geometry, postgis_getbbox(g) AS box from geom;
-- Triangle should collapse if requested
-SELECT '16', ST_AsText(ST_Simplify('TRIANGLE ((0 0, 0 9, 9 0, 0 0))', 10, true));
-SELECT '17', ST_AsText(ST_Simplify('TRIANGLE ((0 0, 0 9, 9 0, 0 0))', 10, false));
\ No newline at end of file
+SELECT '16', ST_AsText(ST_Simplify('TRIANGLE ((0 0, 0 9, 9 0, 0 0))'::geometry, 10, true));
+SELECT '17', ST_AsText(ST_Simplify('TRIANGLE ((0 0, 0 9, 9 0, 0 0))'::geometry, 10, false));
diff --git a/regress/dumper/Makefile.in b/regress/dumper/Makefile.in
index 5d24128..b6f4013 100644
--- a/regress/dumper/Makefile.in
+++ b/regress/dumper/Makefile.in
@@ -16,3 +16,5 @@ topsrcdir = $(realpath ../../)
include tests.mk
include ../runtest.mk
+
+check: check-regress
diff --git a/regress/loader/Makefile.in b/regress/loader/Makefile.in
index 26244d7..d8e6b3b 100644
--- a/regress/loader/Makefile.in
+++ b/regress/loader/Makefile.in
@@ -17,3 +17,5 @@ topsrcdir = $(realpath ../../)
include tests.mk
include ../runtest.mk
+
+check: check-regress
diff --git a/regress/runtest.mk b/regress/runtest.mk
index 90a4764..cd4cf26 100644
--- a/regress/runtest.mk
+++ b/regress/runtest.mk
@@ -5,11 +5,15 @@ TESTS := $(patsubst $(topsrcdir)/%,$(abstopsrcdir)/%,$(TESTS))
TESTS := $(patsubst $(abssrcdir)/%,./%,$(TESTS))
-check:
+check-regress:
- $(PERL) $(topsrcdir)/regress/run_test.pl $(RUNTESTFLAGS) $(TESTS)
- # only run upgrade test if RUNTESTFLAGS was not already doing that
- if echo "$(RUNTESTFLAGS)" | grep -vq -- --upgrade; then \
+ @$(PERL) $(topsrcdir)/regress/run_test.pl $(RUNTESTFLAGS) $(TESTS)
+
+ #
+ # Will now run upgrade test if RUNTESTFLAGS was not already doing that
+ #
+
+ @if echo "$(RUNTESTFLAGS)" | grep -vq -- --upgrade; then \
$(PERL) $(topsrcdir)/regress/run_test.pl --upgrade $(RUNTESTFLAGS) $(TESTS); \
fi
diff --git a/regress/sfcgal/Makefile.in b/regress/sfcgal/Makefile.in
index 00bdc77..687f73a 100644
--- a/regress/sfcgal/Makefile.in
+++ b/regress/sfcgal/Makefile.in
@@ -18,3 +18,5 @@ topsrcdir = $(realpath ../../)
include tests.mk
include ../runtest.mk
+
+check: check-regress
diff --git a/topology/test/Makefile.in b/topology/test/Makefile.in
index 9783b03..cef9108 100644
--- a/topology/test/Makefile.in
+++ b/topology/test/Makefile.in
@@ -27,16 +27,18 @@ topo_predicates.sql: predicates.sql.in
cpp -P -traditional-cpp predicates.sql.in | sed -e 's:@COLUMN@:feature:g;s:@SCHEMA@:topology.:g' > topo_predicates.sql
load_topology.sql: load_topology.sql.in
- @cpp -P -traditional-cpp load_topology.sql.in | sed -e 's:@SRID@:-1:g' > load_topology.sql
+ cpp -P -traditional-cpp load_topology.sql.in | sed -e 's:@SRID@:-1:g' > load_topology.sql
load_topology-4326.sql: load_topology.sql.in
- @cpp -P -traditional-cpp load_topology.sql.in | sed -e 's:@SRID@:4326:g' > load_topology-4326.sql
+ cpp -P -traditional-cpp load_topology.sql.in | sed -e 's:@SRID@:4326:g' > load_topology-4326.sql
clean distclean:
rm -f topo_predicates.sql load_topology.sql load_topology-4326.sql
-check-regress: check
-check: topo_predicates.sql load_topology.sql load_topology-4326.sql
+check: check-regress
+check-regress: check-regress-deps
+
+check-regress-deps: topo_predicates.sql load_topology.sql load_topology-4326.sql
override RUNTESTFLAGS := $(RUNTESTFLAGS) --topology
-----------------------------------------------------------------------
Summary of changes:
GNUmakefile.in | 31 ++++++++-
raster/test/regress/Makefile.in | 4 +-
raster/test/regress/tests.mk | 138 ++++++++++++++++++++++++++++++++++++++++
regress/Makefile.in | 2 +-
regress/core/Makefile.in | 2 +
regress/core/simplify.sql | 34 +++++-----
regress/dumper/Makefile.in | 2 +
regress/loader/Makefile.in | 2 +
regress/runtest.mk | 12 ++--
regress/sfcgal/Makefile.in | 2 +
topology/test/Makefile.in | 10 +--
11 files changed, 210 insertions(+), 29 deletions(-)
create mode 100644 raster/test/regress/tests.mk
hooks/post-receive
--
PostGIS
More information about the postgis-tickets
mailing list