Commit 8ef01a32 authored by Christoph Berg's avatar Christoph Berg

t: Move $delay to TestLib.pm and increase to 500ms.

parent fa4899b7
postgresql-common (148) UNRELEASED; urgency=low
* t: Move $delay to TestLib.pm and increase to 500ms.
-- Christoph Berg <myon@debian.org> Sat, 20 Jul 2013 15:03:02 +0200
postgresql-common (147) unstable; urgency=low
* Bump "really142" to "really146" to fix an error on apt.postgresql.org.
......
......@@ -13,8 +13,6 @@ use TestLib;
use Test::More tests => 29;
my $delay = 200_000; # 200ms
my $tdir = tempdir (CLEANUP => 1);
$PgCommon::confroot = $tdir;
......
......@@ -14,8 +14,6 @@ use PgCommon;
use Test::More tests => 123 * ($#MAJORS+1);
my $delay = 200_000; # 200ms
sub check_major {
my $v = $_[0];
......
......@@ -129,7 +129,7 @@ if (!$psql) {
dup2(POSIX::open('/dev/null', POSIX::O_WRONLY), 2);
exec 'psql', 'template1' or die "could not exec psql process: $!";
}
usleep 200_000; # 200ms
usleep $delay;
like_program_out 0, "pg_upgradecluster $upgrade_options $MAJORS[0] upgr", 1,
qr/Error: Could not stop old cluster/,
......
......@@ -21,11 +21,14 @@ use Test::More;
our $VERSION = 1.00;
our @ISA = ('Exporter');
our @EXPORT = qw/ps ok_dir exec_as deb_installed is_program_out
like_program_out unlike_program_out pidof pid_env check_clean @MAJORS/;
like_program_out unlike_program_out pidof pid_env check_clean
@MAJORS $delay/;
use lib '/usr/share/postgresql-common';
use PgCommon qw/get_versions change_ugid/;
our @MAJORS = $ENV{PG_VERSIONS} ? split (/\s+/, $ENV{PG_VERSIONS}) : sort (get_versions());
our $delay = 500_000; # 500ms
# called if a test fails; spawn a shell if the environment variable
# FAILURE=shell is set
......
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