extract-testsuite-summary.pl 1016 B

123456789101112131415161718192021222324252627282930
  1. #! /usr/bin/env perl
  2. # Extract the testsuite summary generated by the parallel testsuite
  3. # harness from the output of "make check".
  4. # Copyright (C) 2012-2017 Free Software Foundation, Inc.
  5. # This program is free software; you can redistribute it and/or modify
  6. # it under the terms of the GNU General Public License as published by
  7. # the Free Software Foundation; either version 2, or (at your option)
  8. # any later version.
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. # You should have received a copy of the GNU General Public License
  14. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. use warnings FATAL => 'all';
  16. use strict;
  17. my $br = '=' x 76;
  18. my @sections = ('');
  19. while (<>)
  20. {
  21. push @sections, $_, '' if /$br/;
  22. $sections[-1] .= $_ if !/$br/;
  23. }
  24. print @sections[1..$#sections-1];