diff options
author | Andrew Dunstan <andrew@dunslane.net> | 2021-03-21 11:52:30 -0400 |
---|---|---|
committer | Andrew Dunstan <andrew@dunslane.net> | 2021-03-21 11:56:09 -0400 |
commit | 677271a3a125e294b33b891669f594a2c8cb36ce (patch) | |
tree | 87305416e0a50dc708e20826628b1d0fb96e8c20 /src | |
parent | 9fb9691a88ae8df9bc30e0f0f72de7c96e73e125 (diff) |
Unbreak recovery test on Windows
On Windows we need to send explicit quit messages to psql or the TAP tests
can hang.
Diffstat (limited to 'src')
-rw-r--r-- | src/test/recovery/t/022_crash_temp_files.pl | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/test/recovery/t/022_crash_temp_files.pl b/src/test/recovery/t/022_crash_temp_files.pl index c5624fe8644..03c8ae3bd71 100644 --- a/src/test/recovery/t/022_crash_temp_files.pl +++ b/src/test/recovery/t/022_crash_temp_files.pl @@ -124,8 +124,10 @@ $killme_stderr2 = ''; my $ret = TestLib::system_log('pg_ctl', 'kill', 'KILL', $pid); is($ret, 0, 'killed process with KILL'); -# Close psql session +# Explicitly shut down psql gracefully - to avoid hangs or worse on windows +$killme_stdin .= "\\q\n"; $killme->finish; +$killme_stdin2 .= "\\q\n"; $killme2->finish; # Wait till server restarts @@ -212,8 +214,10 @@ $killme_stderr2 = ''; $ret = TestLib::system_log('pg_ctl', 'kill', 'KILL', $pid); is($ret, 0, 'killed process with KILL'); -# Close psql session +# Explicitly shut down psql gracefully - to avoid hangs or worse on windows +$killme_stdin .= "\\q\n"; $killme->finish; +$killme_stdin2 .= "\\q\n"; $killme2->finish; # Wait till server restarts |