summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--t/02_disk_space.t11
1 files changed, 10 insertions, 1 deletions
diff --git a/t/02_disk_space.t b/t/02_disk_space.t
index 0dee62a9b..7226a627d 100644
--- a/t/02_disk_space.t
+++ b/t/02_disk_space.t
@@ -6,10 +6,19 @@ use 5.006;
use strict;
use warnings;
use Data::Dumper;
-use Test::More tests => 8;
+use Test::More;
use lib 't','.';
use CP_Testing;
+# df might fail in chroot environments, e.g. on build daemons where
+# check-postgres packages are built
+system "df > /dev/null 2>&1";
+if ($?) {
+ plan skip_all => 'Skipping disk_space tests because df does not work';
+} else {
+ plan tests => 8;
+}
+
use vars qw/$dbh $result $t $host $dbname/;
my $cp = CP_Testing->new( {default_action => 'disk_space'} );