lib/WWW/Shopify/Liquid/Tag/Free.pm

filter: Statementstmt 45.4% 10 / 22 Branchbran 0.0% 0 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 37.5% 3 / 8 Podpod 0.0% 0 / 5 totaltotal 33.3% 13 / 39 CC 3 SCAR 11.9
CC
3
Cov
38%
abstract
6.0
process
6.0
is_free
2.0
CRAP 3.3
« lib/WWW/Shopify/Liquid/Filter/Split.pm ↑ Summary lib/WWW/Shopify/Liquid/Dialect/Shopify/Filter/ProductImgUrl.pm »
1 #!/usr/bin/perl
2 38 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 38 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 package WWW::Shopify::Liquid::Tag::Free;
6 38 ▶use base 'WWW::Shopify::Liquid::Tag';
Subroutine BEGIN: called CC=1 SCAR=0.0
7 0 ▶sub is_free { return 1; }
Subroutine is_free: not called CC=1 SCAR=6.9
Pod undocumented
8 0 ▶sub abstract { my $package = ref($_[0]) ? ref($_[0]) : $_[0]; return ($package eq __PACKAGE__); }
Subroutine abstract: not called CC=2 SCAR=17.9
Pod undocumented
Branch: 1 branch
BranchTrueFalseTotal
ref $_[0] ? : 0 0 0
9 0 ▶sub subelements { qw(arguments); }
Subroutine subelements: not called CC=1 SCAR=6.9
Pod undocumented
10  
11 0 ▶sub new {
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
12 0 my ($package, $line, $tag, $arguments) = @_;
13 0 my $self = { line => $line, core => $tag, arguments => $arguments };
14 0 return bless $self, $package;
15 }
16  
17 0 ▶sub process {
Subroutine process: not called CC=2 SCAR=17.9
Pod undocumented
18 0 my ($self, $hash, $action, $pipeline) = @_;
19 0 my $arguments = $self->process_subelement($hash, $action, $pipeline, $self->{arguments});
20 0 ▶ return $self unless int(grep { !$self->is_processed($_) } @$arguments) == 0;
Branch: 1 branch
BranchTrueFalseTotal
unless int grep({not $self->is_processed($_);} @$arguments) == 0 0 0 0
21 0 return $self->operate($hash, @$arguments);
22 }
23  
24 38 1;
« lib/WWW/Shopify/Liquid/Filter/Split.pm ↑ Summary lib/WWW/Shopify/Liquid/Dialect/Shopify/Filter/ProductImgUrl.pm »