mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-08-20 04:13:07 +02:00
Unit Tests
- Longer test script names need wider padding. - Added counts for skipped tests.
This commit is contained in:
parent
29dff399bd
commit
11dab68fce
1 changed files with 11 additions and 3 deletions
|
@ -7,17 +7,25 @@ if (open my $fh, '<', 'all.log')
|
|||
{
|
||||
my $test_file;
|
||||
my %errors;
|
||||
my %skipped;
|
||||
|
||||
while (my $line = <$fh>)
|
||||
{
|
||||
$test_file = $1 if $line =~ /^# (\S+\.t)$/;
|
||||
$errors{$test_file}++ if $line =~ /^not /;
|
||||
$test_file = $1 if $line =~ /^# (\S+\.t)$/;
|
||||
$errors{$test_file}++ if $line =~ /^not /;
|
||||
$skipped{$test_file}++ if $line =~ /^skip /;
|
||||
}
|
||||
|
||||
close $fh;
|
||||
|
||||
printf "%-24s %4d\n", $_, $errors{$_}
|
||||
print "Failed\n";
|
||||
printf "%-32s %4d\n", $_, $errors{$_}
|
||||
for sort {$errors{$b} <=> $errors{$a}} keys %errors;
|
||||
|
||||
print "\n";
|
||||
print "Skipped\n";
|
||||
printf "%-32s %4d\n", $_, $skipped{$_}
|
||||
for sort {$skipped{$b} <=> $skipped{$a}} keys %skipped;
|
||||
}
|
||||
|
||||
exit 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue