}
my $node = PostgreSQL::Test::Cluster->new('main');
-$node->init('auth_extra' => [ '--create-role' => 'regress_user1' ]);
+$node->init(auth_extra => [ '--create-role' => 'regress_user1' ]);
$node->append_conf('postgresql.conf',
"session_preload_libraries = 'auto_explain'");
$node->append_conf('postgresql.conf', "auto_explain.log_min_duration = 0");
# Make sure pg_hba.conf is set up to allow connections from backupuser.
# This is only needed on Windows machines that don't use UNIX sockets.
$node->init(
- 'allows_streaming' => 1,
- 'auth_extra' => [ '--create-role' => 'backupuser' ]);
+ allows_streaming => 1,
+ auth_extra => [ '--create-role' => 'backupuser' ]);
$node->append_conf('postgresql.conf',
"shared_preload_libraries = 'basebackup_to_shell'");
$node2->init_from_backup(
$node, 'tarbackup2',
tar_program => $tar,
- 'tablespace_map' => { $tblspcoid => $realRepTsDir });
+ tablespace_map => { $tblspcoid => $realRepTsDir });
$node2->start;
my $result = $node2->safe_psql('postgres', 'SELECT * FROM test1');
# Set up an instance.
my $node = PostgreSQL::Test::Cluster->new('main');
-$node->init('allows_streaming' => 1);
+$node->init(allows_streaming => 1);
$node->start();
# Create an in-place tablespace.
# then stop recovery at some arbitrary LSN, not just when it hits the end of
# WAL, so use a recovery target.
my $node2 = PostgreSQL::Test::Cluster->new('node2');
-$node2->init_from_backup($node1, 'backup1', 'has_streaming' => 1);
+$node2->init_from_backup($node1, 'backup1', has_streaming => 1);
$node2->append_conf('postgresql.conf', <<EOM);
recovery_target_lsn = '$lsn'
recovery_target_action = 'pause'
# Create a PG instance to test actually dumping from
my $node = PostgreSQL::Test::Cluster->new('main');
-$node->init('auth_extra' => [ '--create-role' => 'regress_dump_login_role' ]);
+$node->init(auth_extra => [ '--create-role' => 'regress_dump_login_role' ]);
$node->start;
my $port = $node->port;
PostgreSQL::Test::RecursiveCopy::copypath(
$backup_path,
$data_path,
- 'filterfn' => sub {
+ filterfn => sub {
my ($path) = @_;
if ($path =~ /^pg_tblspc\/(\d+)$/
&& exists $params{tablespace_map}{$1})
# Initialize the server with specific low connection limits
my $node = PostgreSQL::Test::Cluster->new('primary');
$node->init(
- 'auth_extra' => [
+ auth_extra => [
'--create-role' =>
'regress_regular,regress_reserved,regress_superuser',
]);
$ssl_server->configure_test_server_for_ssl(
$node, $SERVERHOSTADDR, $SERVERHOSTCIDR,
"scram-sha-256",
- 'password' => "pass",
- 'password_enc' => "scram-sha-256");
+ password => "pass",
+ password_enc => "scram-sha-256");
switch_server_cert($node, certfile => 'server-cn-only');
$ENV{PGPASSWORD} = "pass";
$common_connstr =
$result = $node->safe_psql(
"trustdb",
"SELECT ssl_client_cert_present();",
- connstr => "$common_connstr dbname=trustdb $c->{'opts'}");
- is($result, $c->{'present'},
- "ssl_client_cert_present() for $c->{'opts'}");
+ connstr => "$common_connstr dbname=trustdb $c->{opts}");
+ is($result, $c->{present}, "ssl_client_cert_present() for $c->{opts}");
}
done_testing();