[pkg-perl-tools] 04/05: Support executing debian/tests/pkg-perl/smoke-setup as a last resort
Niko Tyni
ntyni at moszumanska.debian.org
Sat Sep 26 06:21:58 UTC 2015
This is an automated email from the git hooks/post-receive script.
ntyni pushed a commit to branch ntyni/autopkgtest
in repository pkg-perl-tools.
commit 744754c913b49d9b62d7b92cce2678f9d7108eeb
Author: Niko Tyni <ntyni at debian.org>
Date: Fri Sep 25 23:06:08 2015 +0300
Support executing debian/tests/pkg-perl/smoke-setup as a last resort
A small number of packages need specific tweaks like creating
directories or generating part of the test suite before actually
running it, and there's a point where declarative configuration
just doesn't work anymore.
Closes: #799486
---
autopkgtest/README.autopkgtest | 7 +++++++
autopkgtest/scripts/build-deps.d/smoke | 7 +++++++
2 files changed, 14 insertions(+)
diff --git a/autopkgtest/README.autopkgtest b/autopkgtest/README.autopkgtest
index ee6fc52..fef18a8 100644
--- a/autopkgtest/README.autopkgtest
+++ b/autopkgtest/README.autopkgtest
@@ -50,3 +50,10 @@ matched as fixed substrings (not regular expressions.) Empty lines and
The environment variables AUTOMATED_TESTING=1 and NONINTERACTIVE_TESTING=1
are set by default for the smoke test. You can override these and add
others in 'debian/tests/pkg-perl/smoke-env'.
+
+If the file 'debian/tests/pkg-perl/smoke-setup' exists and is executable,
+it will be executed right before running the tests, with the working
+directory set to the package source and $TDIR set to the test running
+directory. The testing gets aborted if this program returns a nonzero
+value. Please use this facility responsibly and only as a last resort
+if the other hooks don't work for you.
diff --git a/autopkgtest/scripts/build-deps.d/smoke b/autopkgtest/scripts/build-deps.d/smoke
index 93e31af..86978ac 100755
--- a/autopkgtest/scripts/build-deps.d/smoke
+++ b/autopkgtest/scripts/build-deps.d/smoke
@@ -92,6 +92,13 @@ if [ ! -e $TDIR/MANIFEST.SKIP ]; then
cp /dev/null $TDIR/MANIFEST.SKIP
fi
+# this is intended to be a last resort, please use it responsibly
+setup_file=debian/tests/pkg-perl/smoke-setup
+if [ -x $setup_file ]
+then
+ $setup_file
+fi
+
cd $TDIR
if command -v xvfb-run >/dev/null
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/pkg-perl-tools.git
More information about the Pkg-perl-cvs-commits
mailing list