From bc84b55c07336af0f318f152f7985cec846a6b76 Mon Sep 17 00:00:00 2001 From: Adam Guo Date: Mon, 18 Dec 2023 17:38:29 +0000 Subject: [PATCH] Fix tap test --- test/t/004_pg_tle_clientauth.pl | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/t/004_pg_tle_clientauth.pl b/test/t/004_pg_tle_clientauth.pl index b3c4df6..93b96fe 100644 --- a/test/t/004_pg_tle_clientauth.pl +++ b/test/t/004_pg_tle_clientauth.pl @@ -207,7 +207,7 @@ ['psql', '-c', 'select;'], "can still connect if database is in pgtle.clientauth_databases_to_skip"); -$node->psql('postgres', qq[SELECT pgtle.register_feature('reject_testuser', 'clientauth'))]); +$node->psql('postgres', qq[SELECT pgtle.register_feature('reject_testuser', 'clientauth')]); ### 12. Users cannot log in when pgtle.enable_clientauth = 'require' and pg_tle is not installed on pgtle.clientauth_database_name $node->psql('postgres', qq[DROP EXTENSION pg_tle CASCADE;]); @@ -235,7 +235,9 @@ ### 14. Database does not come up if clientauth workers fail to start $node->append_conf('postgresql.conf', qq(pgtle.clientauth_num_parallel_workers = 64)); $node->append_conf('postgresql.conf', qq(max_worker_processes = 63)); -like($node->restart(fail_ok => 1), qr/^0$/); # $node->restart returns 0 on failure +$node->command_fails( + [ 'pg_ctl', '-D', $node->data_dir, '-l', $node->logfile, 'restart' ], + "postmaster does not start up if clientauth workers fail to start"); $node->append_conf('postgresql.conf', qq(pgtle.clientauth_num_parallel_workers = 60)); $node->append_conf('postgresql.conf', qq(max_worker_processes = 63)); $node->restart;