On Sat, Jan 08, 2022 at 02:22:23PM +0900, Michael Paquier wrote: > 2) crake fails perl-check > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=crake&dt=2022-01-08%2002%3A47%3A26 > > All the failures are the same, because of the shape of the subroutine > definitions: > Jan 07 21:53:04 ./src/test/subscription/t/027_nosuperuser.pl: > Subroutine prototypes used at line 13, column 1. See page 194 of > PBP. ([Subroutines::ProhibitSubroutinePrototypes] Severity: 5)
This issue is just caused by the way the subroutines are defined, meaning that the attached cools down pgperlcritic. Any objections if I apply that to cool down crake? Jeff, if you wish to do so, please feel free of course. -- Michael
diff --git a/src/test/subscription/t/027_nosuperuser.pl b/src/test/subscription/t/027_nosuperuser.pl
index 742a745cf7..c9e4aeba06 100644
--- a/src/test/subscription/t/027_nosuperuser.pl
+++ b/src/test/subscription/t/027_nosuperuser.pl
@@ -10,7 +10,7 @@ use Test::More tests => 100;
my ($node_publisher, $node_subscriber, $publisher_connstr, $result, $offset);
$offset = 0;
-sub publish_insert($$)
+sub publish_insert
{
my ($tbl, $new_i) = @_;
$node_publisher->safe_psql('postgres', qq(
@@ -19,7 +19,7 @@ sub publish_insert($$)
));
}
-sub publish_update($$$)
+sub publish_update
{
my ($tbl, $old_i, $new_i) = @_;
$node_publisher->safe_psql('postgres', qq(
@@ -28,7 +28,7 @@ sub publish_update($$$)
));
}
-sub publish_delete($$)
+sub publish_delete
{
my ($tbl, $old_i) = @_;
$node_publisher->safe_psql('postgres', qq(
@@ -37,7 +37,7 @@ sub publish_delete($$)
));
}
-sub expect_replication($$$$$)
+sub expect_replication
{
my ($tbl, $cnt, $min, $max, $testname) = @_;
$node_publisher->wait_for_catchup('admin_sub');
@@ -46,7 +46,7 @@ sub expect_replication($$$$$)
is ($result, "$cnt|$min|$max", $testname);
}
-sub expect_failure($$$$$$)
+sub expect_failure
{
my ($tbl, $cnt, $min, $max, $re, $testname) = @_;
$offset = $node_subscriber->wait_for_log($re, $offset);
@@ -55,28 +55,28 @@ sub expect_failure($$$$$$)
is ($result, "$cnt|$min|$max", $testname);
}
-sub revoke_superuser($)
+sub revoke_superuser
{
my ($role) = @_;
$node_subscriber->safe_psql('postgres', qq(
ALTER ROLE $role NOSUPERUSER));
}
-sub grant_superuser($)
+sub grant_superuser
{
my ($role) = @_;
$node_subscriber->safe_psql('postgres', qq(
ALTER ROLE $role SUPERUSER));
}
-sub revoke_bypassrls($)
+sub revoke_bypassrls
{
my ($role) = @_;
$node_subscriber->safe_psql('postgres', qq(
ALTER ROLE $role NOBYPASSRLS));
}
-sub grant_bypassrls($)
+sub grant_bypassrls
{
my ($role) = @_;
$node_subscriber->safe_psql('postgres', qq(
signature.asc
Description: PGP signature
