Francois Gouget : testbot/web: Let GetHtmlLine() detect and format the timeout errors.

Alexandre Julliard julliard at winehq.org
Wed Jun 27 12:45:44 CDT 2018


Module: tools
Branch: master
Commit: b03a5e895e9e6dd6f673938a8ccd9fd54b4538bc
URL:    https://source.winehq.org/git/tools.git/?a=commit;h=b03a5e895e9e6dd6f673938a8ccd9fd54b4538bc

Author: Francois Gouget <fgouget at codeweavers.com>
Date:   Wed Jun 27 08:09:49 2018 +0200

testbot/web: Let GetHtmlLine() detect and format the timeout errors.

It already handles filtering and highlighting errors so it makes sense
to also have if reformat the timeout errors for the log summary.

Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 testbot/web/JobDetails.pl | 15 ++++++---------
 1 file changed, 6 insertions(+), 9 deletions(-)

diff --git a/testbot/web/JobDetails.pl b/testbot/web/JobDetails.pl
index e5f7929..e7e53d2 100644
--- a/testbot/web/JobDetails.pl
+++ b/testbot/web/JobDetails.pl
@@ -253,6 +253,11 @@ sub GetHtmlLine($$$)
   return undef if ($Category ne "error" and !$FullLog);
 
   my $Html = $self->escapeHTML($Line);
+  if (!$FullLog and $Html =~ m/^[^:]+:([^:]*)(?::[0-9a-f]+)? done \(258\)/)
+  {
+    my $Unit = $1;
+    return $Unit ne "" ? "$Unit: Timeout" : "Timeout";
+  }
   if ($FullLog and $Category ne "none")
   {
     # Highlight all line categories in the full log
@@ -414,15 +419,7 @@ sub GenerateBody($)
           print "<pre><code>";
           $LogFirst = 0;
         }
-        if (!$MoreInfo->{Full} && $Line =~ m/^[^:]+:([^:]*)(?::[0-9a-f]+)? done \(258\)/)
-        {
-          my $Unit = $1 ne "" ? "$1: " : "";
-          print "${Unit}Timeout\n";
-        }
-        else
-        {
-          print "$Html\n";
-        }
+        print "$Html\n";
       }
       close($LogFile);
 




More information about the wine-cvs mailing list