Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Heuristically guess that a supposed fail when there is a skip:null pa…
…ir in the JSON was actually an intentional (but code-based) skip
  • Loading branch information
japhb committed Feb 2, 2013
1 parent bba8568 commit 575c02c
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions analyze
Expand Up @@ -275,8 +275,10 @@ sub summarize_results_text {
}
else {
# XXXX: May have to make this based on key instead of name
my $is_skip = !defined $test->{conf}{$perl->{group}}
|| grep { $_ eq $perl->{name} } @{$test->{conf}{skip} || []};
my $conf = $test->{conf};
my $is_skip = !defined $conf->{$perl->{group}}
|| (grep { $_ eq $perl->{name} } @{$conf->{skip} || []})
|| (exists $conf->{skip} && !defined $conf->{skip});
$output .= sprintf "$spacer$RED%${longest_perl}s $CLEAR",
$is_skip ? 'SKIP' : 'FAIL';
}
Expand Down Expand Up @@ -410,8 +412,10 @@ CSS
}
else {
# XXXX: May have to make this based on key instead of name
my $is_skip = !defined $test->{conf}{$perl->{group}}
|| grep { $_ eq $perl->{name} } @{$test->{conf}{skip} || []};
my $conf = $test->{conf};
my $is_skip = !defined $conf->{$perl->{group}}
|| (grep { $_ eq $perl->{name} } @{$conf->{skip} || []})
|| (exists $conf->{skip} && !defined $conf->{skip});
my $class = $is_skip ? 'bench_skip' : 'bench_fail';
my $message = $is_skip ? 'SKIP' : 'FAIL';
$html .= qq{ <td class="$class">$message</td>\n};
Expand Down

0 comments on commit 575c02c

Please sign in to comment.