From: Greg Sabino Mullane Date: Fri, 1 May 2009 20:57:16 +0000 (-0400) Subject: Testing tweaks. X-Git-Tag: 2.9.0~32 X-Git-Url: http://git.postgresql.org/gitweb/static/gitweb.js?a=commitdiff_plain;h=c9ec2f340e2afc589cd6459f77c5b215aa500ee1;p=check_postgres.git Testing tweaks. --- diff --git a/t/CP_Testing.pm b/t/CP_Testing.pm index 2793cdbef..1e09db31e 100644 --- a/t/CP_Testing.pm +++ b/t/CP_Testing.pm @@ -88,8 +88,6 @@ sub test_database_handle { print $cfh qq{listen_addresses = ''\n}; print $cfh qq{max_connections = 10\n}; print $cfh qq{max_fsm_pages = 99999\n}; - print $cfh qq{stats_block_level = on\n}; - print $cfh qq{stats_row_level = on\n}; ## Grab the version for finicky items if (qx{$initdb --version} !~ /(\d+)\.(\d+)/) { @@ -97,15 +95,23 @@ sub test_database_handle { } my ($maj,$min) = ($1,$2); + ## <= 8.0 if ($maj < 8 or ($maj==8 and $min <= 1)) { print $cfh qq{stats_command_string = on\n}; } + ## ## >= 8.1 if ($maj > 8 or ($maj==8 and $min >= 1)) { print $cfh qq{autovacuum = off\n}; print $cfh qq{max_prepared_transactions = 5\n}; } + ## ## <= 8.2 + if ($maj < 8 or ($maj==8 and $min <= 2)) { + print $cfh qq{stats_block_level = on\n}; + print $cfh qq{stats_row_level = on\n}; + } + print $cfh "\n"; close $cfh or die qq{Could not close "$cfile": $!\n};