Module: tools
Branch: master
Commit: 51d7779e876241c0a39839bb6eee3837379ed092
URL: https://source.winehq.org/git/tools.git/?a=commit;h=51d7779e876241c0a39839b…
Author: Francois Gouget <fgouget(a)codeweavers.com>
Date: Tue Jan 19 18:59:51 2021 +0100
testbot/TestWTBS: Automate checking the Wine TestBot test Suite results.
The Wine TestBot test Suite is a series of Wine pactches that can be
used to verify that the TestBot handles test failures, timeouts, etc
as expected.
The TestWTBS script looks for directives in the commit message of
these patches to automate a range of checks on the corresponding jobs
and tasks.
To simplify parsing the directives, reuse the TestBot's simple errors
cache format.
For instance:
----- TestWTBS -----
p job.Status completed
p tasks.Status completed
p tests.TestFailures 1
----- TestWTBS -----
Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
testbot/tests/TestWTBS | 459 +++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 459 insertions(+)
Diff: https://source.winehq.org/git/tools.git/?a=commitdiff;h=51d7779e876241c0a39…
Module: tools
Branch: master
Commit: 1443b2db4225fbb16e9b64761183ab7c3434f098
URL: https://source.winehq.org/git/tools.git/?a=commit;h=1443b2db4225fbb16e9b647…
Author: Francois Gouget <fgouget(a)codeweavers.com>
Date: Tue Jan 19 18:55:59 2021 +0100
testbot/LogUtils: Add the ToFh suffix to _WriteLogErrors().
This way its name is consistent with LoadLogErrorsFromFh().
Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
testbot/lib/WineTestBot/LogUtils.pm | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/testbot/lib/WineTestBot/LogUtils.pm b/testbot/lib/WineTestBot/LogUtils.pm
index 17be624..30038cf 100644
--- a/testbot/lib/WineTestBot/LogUtils.pm
+++ b/testbot/lib/WineTestBot/LogUtils.pm
@@ -964,7 +964,7 @@ sub LoadLogErrors($)
=pod
=over 12
-=item C<_WriteLogErrors()>
+=item C<_WriteLogErrorsToFh()>
Writes the LogInfo structure in text form to the specified file descriptor.
See _LoadLogErrors() for the format of the errors file.
@@ -972,7 +972,7 @@ See _LoadLogErrors() for the format of the errors file.
=back
=cut
-sub _WriteLogErrors($$)
+sub _WriteLogErrorsToFh($$)
{
my ($Fh, $LogInfo) = @_;
@@ -1000,7 +1000,7 @@ sub _SaveLogErrors($)
my $ErrorsPath = "$LogInfo->{LogPath}.errors";
if (open(my $ErrorsFile, ">", $ErrorsPath))
{
- _WriteLogErrors($ErrorsFile, $LogInfo);
+ _WriteLogErrorsToFh($ErrorsFile, $LogInfo);
close($ErrorsFile);
# Set the mtime so Janitor reaps both at the same time
@@ -1020,7 +1020,7 @@ sub _DumpErrors($$)
next if ($Key =~ /^(?:ErrGroupNames|ErrGroups|NewCount)$/);
print STDERR "+ $Key $LogInfo->{$Key}\n";
}
- _WriteLogErrors(*STDERR, $LogInfo);
+ _WriteLogErrorsToFh(*STDERR, $LogInfo);
}
Module: tools
Branch: master
Commit: e6a493fa40dc999ba64e8f64e7a412ef91497dbb
URL: https://source.winehq.org/git/tools.git/?a=commit;h=e6a493fa40dc999ba64e8f6…
Author: Francois Gouget <fgouget(a)codeweavers.com>
Date: Tue Jan 19 18:55:51 2021 +0100
testbot/LogUtils: Move the .errors format documentation to LoadLogErrors().
Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
testbot/lib/WineTestBot/LogUtils.pm | 60 ++++++++++++++++++-------------------
1 file changed, 30 insertions(+), 30 deletions(-)
diff --git a/testbot/lib/WineTestBot/LogUtils.pm b/testbot/lib/WineTestBot/LogUtils.pm
index 77837fb..1e7dcda 100644
--- a/testbot/lib/WineTestBot/LogUtils.pm
+++ b/testbot/lib/WineTestBot/LogUtils.pm
@@ -822,6 +822,7 @@ sub GetLogLabel($)
return defined $Label ? sprintf($Label, $Extra) : $LogFileName;
}
+
#
# Log errors caching [Part 1]
#
@@ -833,10 +834,36 @@ sub GetLogLabel($)
Loads the specified log errors file.
-See _WriteLogErrors() for the format of the errors file.
-
Returns the errors in the same format as TagNewErrors().
+All lines are of the following form:
+ <type> <value1> <value2>
+
+The values depend on the <type> of the line. <type> and <value1> must not
+contain spaces while <value2> runs to the end of the line.
+More specifically the line formats are:
+=over
+
+=item p <name> <value>
+Property lines contain (name, value) pairs.
+Note that properties which can be calculated while reading the errors file
+are not saved (e.g. ErrCount and NewCount).
+
+=item g <lineno> <groupname>
+Group lines contain the group name and the line number of the first line of
+the group in the log. Note that the first line would typically not be an
+error line.
+A group line should be followed by the old and new error lines in this group.
+
+=item o <lineno> <line>
+Old error lines contain the line number of the error in the log and a verbatim
+copy of that line (with CR/LF converted to a simple LF).
+
+=item n <lineno> <line>
+The format for new error lines is identical to that for old errors but with a
+different type.
+
+=back
=back
=cut
@@ -919,35 +946,8 @@ sub LoadLogErrors($)
=item C<_WriteLogErrors()>
Writes the LogInfo structure in text form to the specified file descriptor.
+See _LoadLogErrors() for the format of the errors file.
-All lines follow are of the following form:
- <type> <value1> <value2>
-
-The values depend on the <type> of the line. <type> and <value1> must not
-contain spaces while <value2> runs to the end of the line. More specifically
-the line formats are:
-=over
-
-=item p <name> <value>
-Property lines contain (name, value) pairs.
-Note that properties which can be calculated while reading the errors file
-are not saved (e.g. ErrCount and NewCount).
-
-=item g <lineno> <groupname>
-Group lines contain the group name and the line number of the first line of
-the group in the log. Note that the first line would typically not be an
-error line.
-A group line should be followed by the old and new error lines in this group.
-
-=item o <lineno> <line>
-Old error lines contain the line number of the error in the log and a verbatim
-copy of that line (with CR/LF converted to a simple LF).
-
-=item n <lineno> <line>
-The format for new error lines is identical to that for old errors but with a
-different type.
-
-=back
=back
=cut