File Coverage

blib/lib/DTL/Fast/Tag/Ifnotequal.pm
Criterion Covered Total %
statement 23 23 100.0
branch n/a
condition n/a
subroutine 8 8 100.0
pod 0 2 0.0
total 31 33 93.9


line stmt bran cond sub pod time code
1             package DTL::Fast::Tag::Ifnotequal;
2 2     2   1017 use strict; use utf8; use warnings FATAL => 'all';
  2     2   3  
  2     2   54  
  2         9  
  2         3  
  2         73  
  2         51  
  2         3  
  2         150  
3 2     2   10 use parent 'DTL::Fast::Tag::Ifequal';
  2         3  
  2         11  
4              
5             $DTL::Fast::TAG_HANDLERS{'ifnotequal'} = __PACKAGE__;
6              
7 2     2   154 use DTL::Fast::Tag::If::Condition;
  2         4  
  2         54  
8 2     2   1010 use DTL::Fast::Expression::Operator::Binary::Ne;
  2         4  
  2         145  
9              
10             #@Override
11 16     16 0 28 sub get_close_tag{ return 'endifnotequal';}
12              
13             #@Override
14             sub add_main_condition
15             {
16 16     16 0 12 my $self = shift;
17 16         10 my $sources = shift;
18 16         13 return $self->add_condition(DTL::Fast::Expression::Operator::Binary::Ne->new(@{$sources}[0,1]));
  16         44  
19             }
20              
21             1;