1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2025-07-13 01:00:23 +02:00

Closed #184: Change test/log directory to test/expect.

This should make it clearer that these are expect logs for regression testing.
This commit is contained in:
David Steele
2016-04-06 10:00:11 -04:00
parent aacc369e4f
commit 8adbcccd02
33 changed files with 5 additions and 5 deletions

View File

@ -207,7 +207,7 @@ sub logWrite
{name => 'strBasePath', trace => true}, {name => 'strBasePath', trace => true},
{name => 'strTestPath', trace => true}, {name => 'strTestPath', trace => true},
{name => 'strFileName', {name => 'strFileName',
default => sprintf("log/$self->{strModule}-$self->{strTest}-%03d.log", $self->{iRun}), trace => true} default => sprintf("expect/$self->{strModule}-$self->{strTest}-%03d.log", $self->{iRun}), trace => true}
); );
my $strReferenceLogFile = "${strBasePath}/test/${strFileName}"; my $strReferenceLogFile = "${strBasePath}/test/${strFileName}";
@ -219,22 +219,22 @@ sub logWrite
} }
else else
{ {
my $strTestLogPath = "${strTestPath}/log"; my $strTestLogPath = "${strTestPath}/expect";
if (!-e $strTestLogPath) if (!-e $strTestLogPath)
{ {
mkdir($strTestLogPath) or mkdir($strTestLogPath) or
confess "unable to create test log path ${strTestLogPath}"; confess "unable to create expect log path ${strTestLogPath}";
} }
$strTestLogFile = "${strTestPath}/${strFileName}"; $strTestLogFile = "${strTestPath}/${strFileName}";
} }
open(my $hFile, '>', $strTestLogFile) open(my $hFile, '>', $strTestLogFile)
or confess "could not open test log file '${strTestLogFile}': $!"; or confess "unable to open expect log file '${strTestLogFile}': $!";
syswrite($hFile, $self->{strLog}) syswrite($hFile, $self->{strLog})
or confess "could not write to test log file '${strTestLogFile}': $!"; or confess "unable to write expect log file '${strTestLogFile}': $!";
close($hFile); close($hFile);