Model/Subtest/Visual.pm

filter: Statementstmt 51.6% 16 / 31 Branchbran 0.0% 0 / 14 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 62.5% 5 / 8 Podpod 100% 3 / 3 totaltotal 42.8% 24 / 56 CC 9 SCAR 27.4
CC
9
Cov
36%
css_class
30.0
link
20.0
popup
6.0
CRAP 15.4
↑ Summary HTMLMatrix.pm »
1 #!/usr/bin/perl
2  
3 package Test::TAP::Model::Subtest::Visual;
4 2 ▶use base qw/Test::TAP::Model::Subtest/;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 2 ▶use URI;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 2 ▶use URI::file;
Subroutine BEGIN: called CC=1 SCAR=0.0
11  
12 0 ▶sub css_class {
Subroutine css_class: not called CC=5 SCAR=34.0
Pod documented
13 0 my $self = shift;
14 0 ▶ return "x sk" if $self->skipped;
Branch: 1 branch
BranchTrueFalseTotal
if $self->skipped 0 0 0
15
16 0 my $todo = $self->todo;
17
18 0 ▶ "x " .
Branch: 3 branches
BranchTrueFalseTotal
$self->actual_ok ? : 0 0 0
$todo ? : 0 0 0
$todo ? : 0 0 0
19 ($self->actual_ok
20 ? ( $todo ? "u" : "p" )
21 : ( $todo ? "t" : "f" ))
22 }
23  
24 0 ▶sub popup {
Subroutine popup: not called CC=2 SCAR=17.9
Pod documented
25 0 my $self = shift;
26 0 my $text = join("\n", $self->line, $self->diag);
27  
28 0 ▶ { chomp $text and redo };
Branch: 1 branch
BranchTrueFalseTotal
chomp $text and redo 0 0 0
29  
30 0 $text;
31 }
32  
33 0 ▶sub link {
Subroutine link: not called CC=4 SCAR=30.0
Pod documented
34 0 my $self = shift;
35 0 my $file = $self->test_file;
36 0 ▶ return URI->new("#") unless $file;
Branch: 1 branch
BranchTrueFalseTotal
unless $file 0 0 0
37  
38 0 my $uri = URI::file->new($file);
39 0 ▶ $_ and $uri->fragment("line_$_") for $self->test_line;
Branch: 1 branch
BranchTrueFalseTotal
$_ and $uri->fragment("line_$_") 0 0 0
40
41 0 return $uri;
42 }
43  
44 2 __PACKAGE__
45  
46 __END__
↑ Summary HTMLMatrix.pm »