[PATCH 3/3] testbot/WineRunTask: Rename the Windows test reports.
Francois Gouget
fgouget at codeweavers.com
Thu Jun 21 07:35:29 CDT 2018
Keep 'log' for the task log messages (such as the compilation log) and
store the actual (WineTest) test report in '.report' files.
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
A coming patch will put the output of the batch file in the log file
(after I have checked that the TestBot VMs have the version of
TestAgentd where redirections work correctly).
testbot/bin/WineRunTask.pl | 16 ++++++++--------
testbot/web/JobDetails.pl | 9 ++++++---
2 files changed, 14 insertions(+), 11 deletions(-)
diff --git a/testbot/bin/WineRunTask.pl b/testbot/bin/WineRunTask.pl
index 7f92b8858..3f5a3ee8d 100755
--- a/testbot/bin/WineRunTask.pl
+++ b/testbot/bin/WineRunTask.pl
@@ -195,7 +195,7 @@ my $OldUMask = umask(002);
my $TaskDir = $Task->CreateDir();
umask($OldUMask);
my $VM = $Task->VM;
-my $RptFileName = $VM->Name . ".rpt";
+my $RptFileName = $Step->FileType .".report";
my $Start = Time();
@@ -292,13 +292,13 @@ sub WrapUpAndExit($;$$$)
if ($Step->Type eq 'suite' and $Status eq 'completed' and !$TimedOut)
{
# Keep the old report if the new one is missing
- if (-f "$TaskDir/log" and !-z "$TaskDir/log")
+ if (-f "$TaskDir/$RptFileName" and !-z "$TaskDir/$RptFileName")
{
# Update the reference VM suite results for WineSendLog.pl
my $LatestBaseName = join("", "$DataDir/latest/", $Task->VM->Name, "_",
$Step->FileType eq "exe64" ? "64" : "32");
unlink("$LatestBaseName.log");
- link("$TaskDir/log", "$LatestBaseName.log");
+ link("$TaskDir/$RptFileName", "$LatestBaseName.log");
unlink("$LatestBaseName.err");
if (-f "$TaskDir/err" and !-z "$TaskDir/err")
{
@@ -518,11 +518,11 @@ if (!defined $TA->Wait($Pid, $Timeout, $Keepalive))
}
my $TimedOut;
-Debug(Elapsed($Start), " Retrieving the report file to 'log'\n");
-if ($TA->GetFile($RptFileName, "$TaskDir/log"))
+Debug(Elapsed($Start), " Retrieving the report file to '$RptFileName'\n");
+if ($TA->GetFile($RptFileName, "$TaskDir/$RptFileName"))
{
- chmod 0664, "$TaskDir/log";
- if (open(my $LogFile, "<", "$TaskDir/log"))
+ chmod 0664, "$TaskDir/$RptFileName";
+ if (open(my $LogFile, "<", "$TaskDir/$RptFileName"))
{
# There is more than one test unit when running the full test suite so keep
# track of the current one. Note that for the TestBot we don't count or
@@ -788,7 +788,7 @@ if ($TA->GetFile($RptFileName, "$TaskDir/log"))
else
{
$NewStatus = 'boterror';
- Error "Unable to open 'log' for reading: $!\n";
+ Error "Unable to open '$RptFileName' for reading: $!\n";
LogTaskError("Unable to open the log file for reading: $!\n");
}
}
diff --git a/testbot/web/JobDetails.pl b/testbot/web/JobDetails.pl
index 3add52b4c..a1a846ff9 100644
--- a/testbot/web/JobDetails.pl
+++ b/testbot/web/JobDetails.pl
@@ -280,9 +280,12 @@ sub GetHtmlLine($$$)
return (undef, $Line);
}
+my @MILogFiles = qw(exe32.report exe64.report log log.old);
my %MILogLabels = (
- "log" => "task log",
- "log.old" => "old logs",
+ "exe32.report" => "32 bit Windows report",
+ "exe64.report" => "64 bit Windows report",
+ "log" => "task log",
+ "log.old" => "old logs",
);
sub InitMoreInfo($)
@@ -298,7 +301,7 @@ sub InitMoreInfo($)
my $Value = $self->GetParam("f$Key");
my $TaskDir = $StepTask->GetTaskDir();
- foreach my $Log ("log", "log.old")
+ foreach my $Log (@MILogFiles)
{
if (!-f "$TaskDir/$Log" or -z "$TaskDir/$Log")
{
--
2.17.1
More information about the wine-devel
mailing list