aboutsummaryrefslogtreecommitdiff
path: root/src/test/perl/PostgresNode.pm
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/perl/PostgresNode.pm')
-rw-r--r--src/test/perl/PostgresNode.pm13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/test/perl/PostgresNode.pm b/src/test/perl/PostgresNode.pm
index b216bbbe4bb..0914fdaa463 100644
--- a/src/test/perl/PostgresNode.pm
+++ b/src/test/perl/PostgresNode.pm
@@ -1324,7 +1324,6 @@ sub safe_psql
print "\n#### End standard error\n";
}
- $stdout =~ s/\r//g if $TestLib::windows_os;
return $stdout;
}
@@ -1515,14 +1514,14 @@ sub psql
if (defined $$stdout)
{
+ $$stdout =~ s/\r\n/\n/g if $TestLib::windows_os;
chomp $$stdout;
- $$stdout =~ s/\r//g if $TestLib::windows_os;
}
if (defined $$stderr)
{
+ $$stderr =~ s/\r\n/\n/g if $TestLib::windows_os;
chomp $$stderr;
- $$stderr =~ s/\r//g if $TestLib::windows_os;
}
# See http://perldoc.perl.org/perlvar.html#%24CHILD_ERROR
@@ -1652,8 +1651,8 @@ sub poll_query_until
{
my $result = IPC::Run::run $cmd, '>', \$stdout, '2>', \$stderr;
+ $stdout =~ s/\r\n/\n/g if $TestLib::windows_os;
chomp($stdout);
- $stdout =~ s/\r//g if $TestLib::windows_os;
if ($stdout eq $expected)
{
@@ -1668,8 +1667,8 @@ sub poll_query_until
# The query result didn't change in 180 seconds. Give up. Print the
# output from the last attempt, hopefully that's useful for debugging.
+ $stderr =~ s/\r\n/\n/g if $TestLib::windows_os;
chomp($stderr);
- $stderr =~ s/\r//g if $TestLib::windows_os;
diag qq(poll_query_until timed out executing this query:
$query
expecting this output:
@@ -2113,8 +2112,8 @@ sub pg_recvlogical_upto
}
};
- $stdout =~ s/\r//g if $TestLib::windows_os;
- $stderr =~ s/\r//g if $TestLib::windows_os;
+ $stdout =~ s/\r\n/\n/g if $TestLib::windows_os;
+ $stderr =~ s/\r\n/\n/g if $TestLib::windows_os;
if (wantarray)
{