Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita475a2f

Browse files
committed
Don't clobber test exit code at cleanup in LDAP/Kerberors tests
If the test script die()d before running the first test, the whole testwas interpreted as SKIPped rather than failed. The PostgreSQL::Clustermodule got this right.Backpatch to all supported versions.Discussion:https://www.postgresql.org/message-id/fb898a70-3a88-4629-88e9-f2375020061d@iki.fi
1 parente13b586 commita475a2f

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

‎src/test/kerberos/t/001_auth.pl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,12 @@
203203

204204
END
205205
{
206+
# take care not to change the script's exit value
207+
my$exit_code =$?;
208+
206209
kill'INT',`cat$kdc_pidfile`ifdefined($kdc_pidfile) &&-f$kdc_pidfile;
210+
211+
$? =$exit_code;
207212
}
208213

209214
note"setting up PostgreSQL instance";

‎src/test/ldap/LdapServer.pm

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,13 +145,18 @@ INIT
145145

146146
END
147147
{
148+
# take care not to change the script's exit value
149+
my$exit_code =$?;
150+
148151
foreachmy$server (@servers)
149152
{
150153
nextunless-f$server->{pidfile};
151154
my$pid = slurp_file($server->{pidfile});
152155
chomp$pid;
153156
kill'INT',$pid;
154157
}
158+
159+
$? =$exit_code;
155160
}
156161

157162
=pod

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp