File Coverage

blib/lib/WWW/Shopify/Liquid/Filter/Within.pm
Criterion Covered Total %
statement 9 14 64.2
branch 0 2 0.0
condition n/a
subroutine 3 6 50.0
pod 0 3 0.0
total 12 25 48.0


line stmt bran cond sub pod time code
1             #!/usr/bin/perl
2 37     37   15289 use strict;
  37         108  
  37         1249  
3 37     37   260 use warnings;
  37         101  
  37         1587  
4              
5             package WWW::Shopify::Liquid::Filter::Within;
6 37     37   399 use base 'WWW::Shopify::Liquid::Filter';
  37         372  
  37         7033  
7            
8 0     0 0   sub min_arguments { return 1; }
9 0     0 0   sub max_arguments { return 1; }
10             sub operate {
11 0     0 0   my ($self, $hash, $operand, $collection) = @_;
12 0 0         return $operand unless $collection;
13 0           return "/collections/" . $collection->{handle} . $operand;
14             }
15              
16             1;