Commit 899d0520 authored by Christoph Berg's avatar Christoph Berg

testsuite: Allow overriding the list of versions to test (-v).

parent 7b9b7923
postgresql-common (144) UNRELEASED; urgency=low
* testsuite: Allow overriding the list of versions to test (-v).
-- Christoph Berg <myon@debian.org> Fri, 10 May 2013 09:55:41 -0700
postgresql-common (143) unstable; urgency=low
* debian/supported-versions: Don't explicitly support 9.3 for
......
# Common functionality for postgresql-common selftests
#
# (C) 2005-2009 Martin Pitt <mpitt@debian.org>
# (C) 2013 Christoph Berg <myon@debian.org>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
......@@ -24,7 +25,7 @@ our @EXPORT = qw/ps ok_dir exec_as deb_installed is_program_out
use lib '/usr/share/postgresql-common';
use PgCommon qw/get_versions change_ugid/;
our @MAJORS = sort (get_versions());
our @MAJORS = $ENV{PG_VERSIONS} ? split (/\s+/, $ENV{PG_VERSIONS}) : sort (get_versions());
# called if a test fails; spawn a shell if the environment variable
# FAILURE=shell is set
......
......@@ -34,15 +34,17 @@ help ()
{
echo "postgresql-common testsuite"
echo "Syntax: $0 [options] [test ...]"
echo " -u 'umask ...' list of umasks to run testsuite with [default: 022 077]"
echo " -u 'umask ...' umasks to run testsuite with [default: 022 077]"
echo " -v 'version ...' PostgreSQL versions to test [default: client versions installed]"
exit ${1:-0}
}
# option parsing
while getopts "hu:" opt ; do
while getopts "hu:v:" opt ; do
case $opt in
h) help ;;
u) PG_UMASKS="$OPTARG" ;;
v) export PG_VERSIONS="$OPTARG" ;; # used in t/TestLib.pm
*) help 1 ;;
esac
done
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment