Pluggable/RDFa.pm

filter: Statementstmt 100% 18 / 18 Branchbran n/a Conditioncond 50.0% 1 / 2 MC/DCmcdc 0.0% 0 / 1 Subroutinesub 100% 6 / 6 Podpod 0.0% 0 / 1 totaltotal 89.2% 25 / 28 CC 2 SCAR 2.7
CC
2
Cov
95%
__ANON__
2.1
init
1.0
BEGIN
1.0
CRAP 1.3
« Pluggable/WhiteList.pm ↑ Summary Pluggable/TinyEntitesEscapeRule.pm »
1 package HTML::Lint::Pluggable::RDFa;
2  
3 1 ▶use 5.008_001;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 1 ▶use parent qw/ HTML::Lint::Pluggable::WhiteList /;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 1 my %rdfa_attrs = map { $_ => 1 } qw/
10 about content datatype inlist prefix property rel resource rev
11 typeof vocab /;
12  
13 2 ▶sub init {
Subroutine init: called CC=1 SCAR=0.0
Pod undocumented
14 2 my ( $class, $lint ) = @_;
15 $class->SUPER::init(
16 $lint => +{
17 rule => +{
18 4 ▶ 'attr-unknown' => sub {
Subroutine __ANON__: called CC=2 SCAR=7.2
19 4 my $param = shift;
20 4 ▶ return exists $rdfa_attrs{ $param->{attr} } || 0;
Condition50%1/2
exists $rdfa_attrs{$param->{'attr'}} || 0
l!l
40
MC/DC0%0/1
exists $rdfa_attrs{$param->{'attr'}} || 0
exists $rdfa_attrs{$param->{'attr'}}
Truth table50%1/2
A
A= exists $rdfa_attrs{$param->{'attr'}}
Aresult
11
00
21 },
22 }
23 }
24 2 );
25 }
26  
27 1 1;
28  
29 __END__
« Pluggable/WhiteList.pm ↑ Summary Pluggable/TinyEntitesEscapeRule.pm »