[tools 2/2] testbot/LogUtils: Detect and report the dll version errors.

Francois Gouget fgouget at codeweavers.com
Tue Apr 6 09:24:58 CDT 2021


There should be no native dll while running the tests in Wine.
Also all expected CreateProcess() errors have explanations. So report
the others as failures.
This also relaxes the GetReportLineCategory() regexps a bit to match
the new 'version error' lines.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=48062
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
 testbot/lib/WineTestBot/LogUtils.pm | 21 ++++++++++++++++++---
 1 file changed, 18 insertions(+), 3 deletions(-)

diff --git a/testbot/lib/WineTestBot/LogUtils.pm b/testbot/lib/WineTestBot/LogUtils.pm
index dde4104b8..e6e89f556 100644
--- a/testbot/lib/WineTestBot/LogUtils.pm
+++ b/testbot/lib/WineTestBot/LogUtils.pm
@@ -325,8 +325,8 @@ sub GetReportLineCategory($)
   {
     return "skip";
   }
-  if ($Line =~ /^    \w+=dll is (?:missing|native|a stub)/ or
-      $Line =~ /^    \w+=(?:load error|version error \d+|version not (?:found|present))$/ or
+  if ($Line =~ /^    \w+=dll is (?:missing|a stub)/ or
+      $Line =~ /^    \w+=(?:version error \d+|version not (?:found|present))/ or
       $Line =~ /^[_.a-z0-9-]+:[_a-z0-9]* start / or
       $Line =~ /: this is the last test seen before the exception/)
   {
@@ -538,6 +538,7 @@ sub ParseWineTestReport($$$)
   }
 
   my $LineNo = 0;
+  my $InDlls = 0;
   my $Cur = _NewCurrentUnit("", "");
   foreach my $Line (<$LogFile>)
   {
@@ -547,7 +548,21 @@ sub ParseWineTestReport($$$)
     chomp $Line;
     $Line =~ s/\r+$//;
 
-    if ($Line =~ m%^([_.a-z0-9-]+):([_a-z0-9]*) (start|skipped) (?:-|[/_.a-z0-9-]+)%)
+    if ($InDlls == 0 and $Line =~ /^Dll info:$/)
+    {
+      $InDlls = 1;
+    }
+    elsif ($InDlls == 1 and
+           $Line =~ /^\s+\S+=(?:dll is native|load error \d+)$/)
+    {
+      _AddReportError($LogInfo, $Cur, $LineNo, $Line);
+      $Cur->{LineFailures}++;
+    }
+    elsif ($Line =~ /^Test output:$/)
+    {
+      $InDlls = 2;
+    }
+    elsif ($Line =~ m%^([_.a-z0-9-]+):([_a-z0-9]*) (start|skipped) (?:-|[/_.a-z0-9-]+)%)
     {
       my ($Dll, $Unit, $Type) = ($1, $2, $3);
 
-- 
2.20.1



More information about the wine-devel mailing list