[Git][debian-gis-team/postgis][experimental] 2 commits: Revert "Drop regress autopkgtest, no longer works."
Christoph Berg (@myon)
gitlab at salsa.debian.org
Sun May 22 22:41:06 BST 2022
Christoph Berg pushed to branch experimental at Debian GIS Project / postgis
Commits:
18e455d9 by Christoph Berg at 2022-05-22T21:38:35+02:00
Revert "Drop regress autopkgtest, no longer works."
This reverts commit 046debb4c94b256fb396d3b7c8cd920897ac6809.
- - - - -
95135c46 by Christoph Berg at 2022-05-22T21:47:28+02:00
Fix regress autopkgtest
Set top_srcdir and builddir when invoking make.
- - - - -
2 changed files:
- debian/tests/control
- + debian/tests/regress
Changes:
=====================================
debian/tests/control
=====================================
@@ -1,3 +1,3 @@
Depends: @, postgresql-server-dev-all, postgresql-all
-Tests: test-extension-creation
+Tests: test-extension-creation regress
Restrictions: allow-stderr, skippable
=====================================
debian/tests/regress
=====================================
@@ -0,0 +1,57 @@
+#!/bin/sh
+
+set -eux
+
+# link shape loader/dumper to where the testsuite expects them
+for prg in shp2pgsql pgsql2shp; do
+ test -x loader/$prg || ln -s /usr/bin/$prg loader/$prg
+done
+
+# delete test directory before possibly switching user
+rm -rf /tmp/pgis_reg
+
+# re-start ourselves as nobody since PG can't run as root
+if [ "$(id -un)" = "root" ]; then
+ exec su nobody -s /bin/sh "$0" "$@"
+fi
+
+# Skip tests on problematic architectures
+ARCH="$(dpkg-architecture -qDEB_BUILD_ARCH)"
+
+if [ "${ARCH}" = "armel" ] || [ "${ARCH}" = "armhf" ] || [ "${ARCH}" = "mips" ] || [ "${ARCH}" = "mips64el" ] || [ "${ARCH}" = "mipsel" ] || [ "${ARCH}" = "s390x" ] || [ "${ARCH}" = "alpha" ] || [ "${ARCH}" = "hppa" ] || [ "${ARCH}" = "hurd-i386" ] || [ "${ARCH}" = "kfreebsd-i386" ] || [ "${ARCH}" = "powerpc" ] || [ "${ARCH}" = "ppc64" ] || [ "${ARCH}" = "sparc64" ]; then
+ echo "Skipping tests on problematic architectures"
+ exit 77
+fi
+
+# clean up on exit
+trap "rm -rf /tmp/pgis_reg" EXIT
+
+# run the regression tests
+for v in $(pg_buildext installed-versions); do
+ case $v in
+ *.*) POSTGIS_PGSQL_VERSION=$(echo $v | tr -d .) ;;
+ *) POSTGIS_PGSQL_VERSION="${v}0" ;;
+ esac
+ case $v in
+ *.*|10) HAVE_SPGIST=no ;;
+ *) HAVE_SPGIST=yes ;;
+ esac
+ pg_virtualenv -v $v <<-EOF
+ echo "### PostgreSQL $v ###"
+ set -eux
+ make -C regress/core -f Makefile.in check \
+ PERL=perl \
+ RUNTESTFLAGS="--extension --verbose" \
+ POSTGIS_PGSQL_VERSION=$POSTGIS_PGSQL_VERSION \
+ HAVE_SPGIST=$HAVE_SPGIST \
+ top_srcdir=$PWD \
+ builddir=$PWD/regress/core
+ make -C sfcgal/regress -f Makefile.in check \
+ PERL=perl \
+ RUNTESTFLAGS="--extension --verbose" \
+ POSTGIS_PGSQL_VERSION=$POSTGIS_PGSQL_VERSION \
+ HAVE_SFCGAL=yes \
+ top_srcdir=$PWD \
+ builddir=$PWD/sfcgal/regress
+ EOF
+done
View it on GitLab: https://salsa.debian.org/debian-gis-team/postgis/-/compare/046debb4c94b256fb396d3b7c8cd920897ac6809...95135c466cc6073cbc7ae13839e899dd1dec2dbe
--
View it on GitLab: https://salsa.debian.org/debian-gis-team/postgis/-/compare/046debb4c94b256fb396d3b7c8cd920897ac6809...95135c466cc6073cbc7ae13839e899dd1dec2dbe
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20220522/5594ce33/attachment-0001.htm>
More information about the Pkg-grass-devel
mailing list