mirror of
https://github.com/postgres/postgres.git
synced 2025-04-25 21:42:33 +03:00
tests: Trim newline from result returned by BackgroundPsql->query
This went unnoticed, because only a few existing callers of BackgroundPsql->query used the result, and the ones that did were not bothered by an extra newline. I noticed because I was about to add a new test that checks the result. Backport to all supported versions, since I just backported the BackgroundPsql facility to all supported versions too.
This commit is contained in:
parent
a2dff271eb
commit
ecbf6ac51d
@ -223,7 +223,7 @@ sub query
|
|||||||
$output = $self->{stdout};
|
$output = $self->{stdout};
|
||||||
|
|
||||||
# remove banner again, our caller doesn't care
|
# remove banner again, our caller doesn't care
|
||||||
$output =~ s/\n$banner$//s;
|
$output =~ s/\n$banner\n$//s;
|
||||||
|
|
||||||
# clear out output for the next query
|
# clear out output for the next query
|
||||||
$self->{stdout} = '';
|
$self->{stdout} = '';
|
||||||
|
Loading…
x
Reference in New Issue
Block a user